function DrupalFlushAllCachesTest::testDrupalFlushAllCachesModuleList
Same name in other branches
- 9 core/tests/Drupal/KernelTests/Core/Common/DrupalFlushAllCachesTest.php \Drupal\KernelTests\Core\Common\DrupalFlushAllCachesTest::testDrupalFlushAllCachesModuleList()
- 10 core/tests/Drupal/KernelTests/Core/Common/DrupalFlushAllCachesTest.php \Drupal\KernelTests\Core\Common\DrupalFlushAllCachesTest::testDrupalFlushAllCachesModuleList()
- 11.x core/tests/Drupal/KernelTests/Core/Common/DrupalFlushAllCachesTest.php \Drupal\KernelTests\Core\Common\DrupalFlushAllCachesTest::testDrupalFlushAllCachesModuleList()
Tests that drupal_flush_all_caches() uses core.extension properly.
File
-
core/
tests/ Drupal/ KernelTests/ Core/ Common/ DrupalFlushAllCachesTest.php, line 21
Class
- DrupalFlushAllCachesTest
- @covers ::drupal_flush_all_caches @group Common
Namespace
Drupal\KernelTests\Core\CommonCode
public function testDrupalFlushAllCachesModuleList() {
$core_extension = \Drupal::configFactory()->getEditable('core.extension');
$module = $core_extension->get('module');
$module['system_test'] = -10;
$core_extension->set('module', module_config_sort($module))
->save();
drupal_flush_all_caches();
$this->assertSame([
'system_test',
'path_alias',
'system',
], array_keys($this->container
->getParameter('container.modules')));
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.