MDL-63711 core_grade: Use canonicalize for checking userlist IDs
authorJun Pataleta <jun@moodle.com>
Tue, 6 Nov 2018 06:15:04 +0000 (14:15 +0800)
committerDavid Monllao <davidm@moodle.com>
Tue, 6 Nov 2018 14:48:30 +0000 (15:48 +0100)
grade/tests/privacy_test.php

index b4d6009..0de9e5a 100644 (file)
@@ -390,12 +390,12 @@ class core_grades_privacy_testcase extends provider_testcase {
         $userlist = new \core_privacy\local\request\userlist($c1ctx, 'core_grades');
         provider::get_users_in_context($userlist);
         $course1userids = [$u1->id, $u2->id, $u3->id, $u4->id];
         $userlist = new \core_privacy\local\request\userlist($c1ctx, 'core_grades');
         provider::get_users_in_context($userlist);
         $course1userids = [$u1->id, $u2->id, $u3->id, $u4->id];
-        $this->assertEquals($course1userids, $userlist->get_userids());
+        $this->assertEquals($course1userids, $userlist->get_userids(), '', 0.0, 10, true);
 
         $userlist = new \core_privacy\local\request\userlist($c2ctx, 'core_grades');
         provider::get_users_in_context($userlist);
         $course2userids = [$u5->id, $u2->id];
 
         $userlist = new \core_privacy\local\request\userlist($c2ctx, 'core_grades');
         provider::get_users_in_context($userlist);
         $course2userids = [$u5->id, $u2->id];
-        $this->assertEquals($course2userids, $userlist->get_userids());
+        $this->assertEquals($course2userids, $userlist->get_userids(), '', 0.0, 10, true);
 
         $userlist = new \core_privacy\local\request\userlist($u2ctx, 'core_grades');
         provider::get_users_in_context($userlist);
 
         $userlist = new \core_privacy\local\request\userlist($u2ctx, 'core_grades');
         provider::get_users_in_context($userlist);