mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-59832 core_course: removed faulty logic in unit test
This commit is contained in:
parent
8c2465eaf0
commit
431723eccc
1 changed files with 0 additions and 17 deletions
|
@ -3024,23 +3024,6 @@ class core_course_courselib_testcase extends advanced_testcase {
|
|||
$this->assertTrue($navoptions->tags);
|
||||
$this->assertTrue($navoptions->search);
|
||||
$this->assertTrue($navoptions->calendar);
|
||||
|
||||
// Standar using viewing frontpage settings from a course where is enrolled.
|
||||
$course = self::getDataGenerator()->create_course();
|
||||
// Create a viewer user.
|
||||
$viewer = self::getDataGenerator()->create_user();
|
||||
$studentrole = $DB->get_record('role', array('shortname' => 'student'));
|
||||
$this->getDataGenerator()->enrol_user($viewer->id, $course->id, $studentrole->id);
|
||||
$this->setUser($viewer);
|
||||
|
||||
$navoptions = course_get_user_navigation_options($context, $course);
|
||||
$this->assertTrue($navoptions->blogs);
|
||||
$this->assertFalse($navoptions->notes);
|
||||
$this->assertTrue($navoptions->participants);
|
||||
$this->assertTrue($navoptions->badges);
|
||||
$this->assertTrue($navoptions->tags);
|
||||
$this->assertTrue($navoptions->search);
|
||||
$this->assertTrue($navoptions->calendar);
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue