MDL-46588 web services: Fixed invalid check of empty contextid in function get_context_from_params
MDL-46588 web services: Unit tests added
MDL-46588 web services: Fixed system context instanceid eq 0 case
Merge branch 'MDL-46588-27' of git://github.com/jleyva/moodle into MOODLE_27_STABLE
MDL-47079 user: behat test for deleting users
MDL-44257 message: check if the attachment exists before remove it

Credit goes to Mark Nielsen, thanks.
MDL-44257 message: added test to make sure the stored file still exists
MDL-44257 lib: fix the attachment code to accept tempdir and dataroot.

Credit goes to Damyon, thanks.
Merge branch 'MDL-44257-27' of git://github.com/lameze/moodle into MOODLE_27_STABLE
MDL-44257 Message: Update phpdocs for email_to_user function
MDL-46613 grades ws: Fixed external function declaration

Gradebook items with overridden grades was causing error as Web
Services response

coding style
Merge branch 'wip-MDL-47079-m27' of git://github.com/marinaglancy/moodle into MOODLE_27_STABLE
Merge branch 'MDL-46613-27' of git://github.com/jleyva/moodle into MOODLE_27_STABLE