50 Commits

Author SHA1 Message Date
Rajesh Taneja
921faad9ad MDL-53571 behat: Use Escaper for escaping
xpathLiteral has been depreacted, use Escaper instead
2016-04-06 15:38:31 +08:00
Rajesh Taneja
eb9ca848fa MDL-53381 behat: Replaced chained steps with api.
Behat 3.x doesn't support chained steps and hence
this is first step to get rid of chained steps in core.
2016-04-06 11:32:49 +08:00
Rajesh Taneja
42ad096fdb MDL-46891 Behat: Added support for behat 3 2016-03-11 10:51:15 +08:00
Andrew Nicols
c57542a8d2 MDL-38020 behat: Correct singleselect usage 2016-01-12 09:31:05 +00:00
Andrew Nicols
a1013a8054 Merge branch 'MDL-38020-master' of git://github.com/danpoltawski/moodle 2016-01-12 09:31:04 +00:00
Juan Leyva
4323a973d5 MDL-52072 enrol: Fix course visibility checks in external functions 2016-01-05 10:31:23 +00:00
Dan Poltawski
d60ae73236 MDL-38020 behat: for enrollment management from participants page 2015-12-30 15:25:31 +00:00
Eloy Lafuente (stronk7)
ed4e707577 MDL-51861 enrol: added missing external cleanup for formal compliance 2015-11-06 10:58:28 +01:00
Andrew Nicols
af8472a91f Merge branch 'MDL-51861' of git://github.com/stronk7/moodle 2015-11-06 15:01:20 +08:00
Andrew Nicols
1d1f08a045 MDL-51685-master Fix unit tests following change
These unit tests were modifying the PAGE and other globals in the middle of
tests and were failing as a result.

Broke the tests up into separate tests where the functionality is now
tested individually.
2015-11-06 10:36:06 +08:00
Eloy Lafuente (stronk7)
f076ce2834 MDL-51861 enrol: new unit test to verify all conditions and filters
This unit test does not verify contents, details, but only
that the returned users for every group mode, for every
filtering (active, groupid and withcapability) together
with permissions are correct.
2015-11-06 02:26:02 +01:00
Rajneel Totaram
494fec0071 MDL-51923 enrol: Enrolment list filter 'No Group' shows incorrect count
With contributions from John Okely
2015-10-28 17:34:16 +08:00
Andrew Nicols
cfd3b94544 Merge branch 'MDL-51341_enrolled_users_filter' of git://github.com/davosmith/moodle 2015-10-08 09:17:29 +08:00
Davo Smith
bf8f915abc MDL-51341 enrolment: fix 'No group' enrolled user filter 2015-10-07 17:09:15 +01:00
Marina Glancy
080c7d471d MDL-44640 enrol: trigger events on instances actions 2015-09-27 17:52:20 +08:00
Andrew Nicols
e8cf6330c2 MDL-50055 enrol: Stop requiring javascript for behat tests 2015-05-05 10:23:18 +08:00
Rajesh Taneja
0fe86bbdbb MDL-49799 behat: replaced asd.com with example.com
asd.com is a valid domain, we should use reserved domain names for testing
2015-04-20 11:21:20 +08:00
Juan Leyva
b4896308dc MDL-45131 enrol: Add validation for returned parameters in WS tests 2015-04-16 10:25:25 +02:00
Andrew Nicols
647681d4e9 Merge branch 'MDL-49687-master' of git://github.com/andrewnicols/moodle 2015-04-08 09:34:37 +08:00
Andrew Nicols
31635bfb63 MDL-49687 enrol: Add behat tests for adding multiple groups 2015-04-08 09:34:16 +08:00
Juan Leyva
ba62015b8e MDL-49606 webservices: Minor style fixes 2015-03-27 12:19:52 +01:00
Daniel Ureña
9b78f0e98b MDL-49606 webservices: Improved unit tests for get_users_courses 2015-03-27 10:12:47 +01:00
David Monllao
d46979ec3a MDL-44620 behat: Automates MDLQA-6
- MDLQA-6: By default, a new course contains a news
forum in which only teachers can post and subscription
is forced
2014-05-13 17:24:33 +07:00
David Monllao
f083d6145e MDL-43738 behat: Updating features files
The following used steps were replaced by the ones
added in this issue:
- I fill the moodle form with
- I fill in with
- I select from
- I select radio button
- I check
- I uncheck
- the field should match

Also removing test for deprecated steps:
- the ASD checkbox should be checked
- the ASD checkbox should not be checked
2014-02-27 18:22:05 +08:00
Frederic Massart
457b82f238 MDL-43337 enrol: Missing break in get_enrolled_users WS 2014-02-13 12:06:04 +08:00
Frederic Massart
e06d359917 MDL-43337 enrol: More tests for get_enrolled_users_with_capability 2014-02-13 12:06:04 +08:00
Rajesh Taneja
623a32e50d MDL-43736 Events: Updated unit test to test context not used in event 2014-01-29 11:39:50 +08:00
Mark Nelson
f1f4f4fd7b MDL-40909 core_enrol: removed 'enrol' add_to_log calls
Before each of these calls a call to enrol_user() is made, which
triggers the event 'user_enrolment_created'. Nothing more is needed.
2014-01-27 19:52:55 -08:00
Mark Nelson
6324517209 MDL-40909 core_enrol: removed 'unenrol' add_to_log calls
Before each of these calls a call to unenrol_user() is made, which
triggers the event 'user_enrolment_deleted'. Nothing more is needed.
2014-01-27 19:52:55 -08:00
Marina Glancy
4a3fb71c4f MDL-41436 Removing references to fields course.modinfo, sectioncache
Also add the field cacherev to the lists of default fields in course retrieval functions
2013-09-10 14:11:51 +10:00
Rajesh Taneja
bb78e249cd MDL-39961 Events: Replace Legacy events - User
This change includes:
* Added user_updated event, replacing old event
* Added user_created event, replacing old event
* Added user_deleted event, replacing old event
* Added user_loggedout event, replacing old event
* Added user_enrolment_created event, replacing old event
* Added user_enrolment_deleted event, replacing old event
* Added user_enrolment_updated event, replacing old event
2013-09-02 16:10:05 +08:00
Dan Poltawski
631d9f661f MDL-41191 enrol: unit tests for enrol_get_shared_courses 2013-08-15 11:50:08 +08:00
Marina Glancy
9be9b412b1 Merge branch 'wip-mdl-40126' of git://github.com/rajeshtaneja/moodle 2013-08-06 22:53:19 +10:00
Petr Škoda
8252b7c291 MDL-40901 standardise core test case class and file names
This finally allows us to type only the class name when executing individual core test cases.
2013-08-04 22:10:31 +02:00
Rajesh Taneja
be9bf94e4a MDL-40126 Enrolments: Implemented two webservices to get enrolment instance info
1. core_enrol_get_course_enrolment_methods() which returns all enrolment method instances
which implement get_enrol_info()
2. enrol_self_get_instance_info() will return information about self enrolment instance.
2013-07-29 15:07:37 +08:00
David Monllao
3897608152 MDL-39635 behat: XPath cleanups
- Escaping steps arguments redirected to other steps
- Adding normalized-space() in all contains() assertions
- General xpaths review
- Convering provided xpath text strings to xpath literals
  to avoid problems with arguments containing both single
  quotes and double quotes
2013-07-19 10:02:36 +02:00
David Monllao
dedb973878 MDL-39635 behat: Replacing hardcoded language strings
Using get_string() instead.
2013-07-19 10:02:10 +02:00
Ankit Agarwal
1e63179285 MDL-39153 webservices: Provide alternative to passing contextids
As per our policy webservices should never have a required contextid, thuse providing a support for passing contextlevel and instanceid as parameters to the api
2013-06-18 14:15:54 +08:00
Ankit Agarwal
aac70ffc18 MDL-39152 webservices: Abstract context fetching
Since many apis in future will need to provide alternative method to fetch context, I have abstracted this bit into the core external_api class
2013-06-14 15:47:48 +08:00
Ankit Agarwal
235b5c680a MDL-39152 phpunit: Move core_role_external_testcase() to a new file
It is not recommended to have multiple test classes in a single phpunit file
2013-06-14 11:50:25 +08:00
Ankit Agarwal
95a3bb4dc8 MDL-39152 phpunit: improve tests for assign_roles()
core_role_external::assign_roles() now support alternative paramaters instead of contextid. Test working of those. Also test the parameters validation a bit, since these are no longer automatically tested being optional now
2013-06-14 11:50:25 +08:00
Petr Škoda
31ac2aef26 MDL-39386 fix phpdocs packages in enrol 2013-04-27 13:41:32 +02:00
Dan Poltawski
fbd90ba191 Merge branch 'MDL-37410-master' of git://github.com/mouneyrac/moodle 2013-04-10 10:37:29 +08:00
David Monllao
f0e4cf5e31 MDL-38619 behat: Step definition to add enrolment methods to courses 2013-03-28 11:17:14 +08:00
Jerome Mouneyrac
909f27acf4 MDL-37410 External PHPunit test: used ->getDataGenerator()->enrol_user instead to manually enrol the user. + improve the unassignUserCapability to remove a capability assigned by getDataGenerator->enrol_users 2013-02-12 11:15:15 +08:00
Jerome Mouneyrac
fb695f6e3d MDL-37354 clean return value for each externallib PHPUnit tests 2013-01-09 13:47:01 +08:00
Petr Škoda
05f6da14f7 MDL-33017 add new function for quickly finding out if user sees at least on course
This will be used in navigation.
2012-11-04 11:08:25 +13:00
Dan Poltawski
21d3bfb39a MDL-31859 - fix more trailing whitespace 2012-09-26 14:44:42 +08:00
Paul Charsley
b6b6c7acb6 MDL-31859 added get_enrolled_users_with_capability web service function 2012-09-21 09:37:06 +12:00
Jerome Mouneyrac
566596abd7 MDL-34967 PHPunit test: enrol/externallib.php and enrol/manual/externallib.php 2012-09-04 12:26:21 +08:00