mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 17:36:38 +02:00
MDL-35382 fix random course test failures
This commit is contained in:
parent
ccd90e765e
commit
3a222db215
1 changed files with 1 additions and 1 deletions
|
@ -70,7 +70,7 @@ class courselib_testcase extends advanced_testcase {
|
||||||
$course = $this->getDataGenerator()->create_course(array('numsections'=>10), array('createsections'=>true));
|
$course = $this->getDataGenerator()->create_course(array('numsections'=>10), array('createsections'=>true));
|
||||||
$oldsections = array();
|
$oldsections = array();
|
||||||
$sections = array();
|
$sections = array();
|
||||||
foreach ($DB->get_records('course_sections', array('course'=>$course->id)) as $section) {
|
foreach ($DB->get_records('course_sections', array('course'=>$course->id), 'id') as $section) {
|
||||||
$oldsections[$section->section] = $section->id;
|
$oldsections[$section->section] = $section->id;
|
||||||
$sections[$section->id] = $section->section;
|
$sections[$section->id] = $section->section;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue