function ModuleTestBase::assertNoModuleConfig
Same name in other branches
- 9 core/modules/system/tests/src/Functional/Module/ModuleTestBase.php \Drupal\Tests\system\Functional\Module\ModuleTestBase::assertNoModuleConfig()
- 8.9.x core/modules/system/src/Tests/Module/ModuleTestBase.php \Drupal\system\Tests\Module\ModuleTestBase::assertNoModuleConfig()
- 8.9.x core/modules/system/tests/src/Functional/Module/ModuleTestBase.php \Drupal\Tests\system\Functional\Module\ModuleTestBase::assertNoModuleConfig()
- 10 core/modules/system/tests/src/Functional/Module/ModuleTestBase.php \Drupal\Tests\system\Functional\Module\ModuleTestBase::assertNoModuleConfig()
Asserts that no configuration exists for a given module.
Parameters
string $module: The name of the module.
2 calls to ModuleTestBase::assertNoModuleConfig()
- ConfigImportAllTest::testInstallUninstall in core/
modules/ config/ tests/ src/ Functional/ ConfigImportAllTest.php - Tests that a fixed set of modules can be installed and uninstalled.
- DependencyTest::testEnableWithoutDependency in core/
modules/ system/ tests/ src/ Functional/ Module/ DependencyTest.php - Attempts to enable the Content Translation module without Language enabled.
File
-
core/
modules/ system/ tests/ src/ Functional/ Module/ ModuleTestBase.php, line 122
Class
- ModuleTestBase
- Helper class for module test cases.
Namespace
Drupal\Tests\system\Functional\ModuleCode
public function assertNoModuleConfig($module) {
$names = \Drupal::configFactory()->listAll($module . '.');
$this->assertEmpty($names, "No configuration found for {$module} module.");
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.