mirror of
https://github.com/moodle/moodle.git
synced 2025-08-06 09:26:35 +02:00
MDL-39915 cleanup core_component_testcase
This commit is contained in:
parent
82ff8e2937
commit
2058e79707
1 changed files with 11 additions and 16 deletions
|
@ -218,8 +218,6 @@ class core_component_testcase extends advanced_testcase {
|
|||
}
|
||||
|
||||
public function test_normalize_component() {
|
||||
global $CFG;
|
||||
|
||||
// Moodle core.
|
||||
$this->assertSame(array('core', null), core_component::normalize_component('core'));
|
||||
$this->assertSame(array('core', null), core_component::normalize_component('moodle'));
|
||||
|
@ -258,8 +256,6 @@ class core_component_testcase extends advanced_testcase {
|
|||
}
|
||||
|
||||
public function test_deprecated_normalize_component() {
|
||||
global $CFG;
|
||||
|
||||
// Moodle core.
|
||||
$this->assertSame(array('core', null), normalize_component('core'));
|
||||
$this->assertSame(array('core', null), normalize_component(''));
|
||||
|
@ -297,7 +293,6 @@ class core_component_testcase extends advanced_testcase {
|
|||
normalize_component('whothefuck_would_come_withsuchastupidnameofcomponent'));
|
||||
}
|
||||
|
||||
|
||||
public function test_get_component_directory() {
|
||||
$plugintypes = core_component::get_plugin_types();
|
||||
foreach ($plugintypes as $plugintype => $fulldir) {
|
||||
|
@ -333,7 +328,7 @@ class core_component_testcase extends advanced_testcase {
|
|||
|
||||
$types = core_component::get_plugin_types_with_subplugins();
|
||||
|
||||
// Hardcode it here to detect if anybody hacks the code to include more types.
|
||||
// Hardcode it here to detect if anybody hacks the code to include more subplugin types.
|
||||
$expected = array(
|
||||
'mod' => "$CFG->dirroot/mod",
|
||||
'editor' => "$CFG->dirroot/lib/editor",
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue