See Release Notes
Long Term Support Release
Differences Between: [Versions 401 and 402] [Versions 401 and 403]
(no description)
File Size: | 350 lines (14 kb) |
Included or required: | 0 times |
Referenced: | 0 times |
Includes or requires: | 0 files |
section_test:: (4 methods):
setupBeforeClass()
test_section_hasrestrictions_state()
setup_hasrestrictions_scenario()
hasrestrictions_state_provider()
Class: section_test - X-Ref
Tests for section state class.setupBeforeClass() X-Ref |
Setup to ensure that fixtures are loaded. |
test_section_hasrestrictions_state(string $format = 'topics',string $rolename = 'editingteacher',bool $hasavailability = false,bool $available = false,bool $expected = false) X-Ref |
Test the behaviour of state\section hasavailability attribute. param: string $format the course format param: string $rolename the user role name (editingteacher or student) param: bool $hasavailability if the activity|section has availability param: bool $available if the activity availability condition is available or not to the user param: bool $expected the expected result |
setup_hasrestrictions_scenario(string $format = 'topics',string $rolename = 'editingteacher',bool $hasavailability = false,bool $available = false) X-Ref |
Setup section or cm has restrictions scenario. param: string $format the course format param: string $rolename the user role name (editingteacher or student) param: bool $hasavailability if the section has availability param: bool $available if the section availability condition is available or not to the user return: stdClass the scenario instances. |
hasrestrictions_state_provider() X-Ref |
Data provider for test_state(). return: array |