function DefaultConfigTest::testDefaultConfig
Same name in other branches
- 8.9.x core/tests/Drupal/KernelTests/Core/Config/DefaultConfigTest.php \Drupal\KernelTests\Core\Config\DefaultConfigTest::testDefaultConfig()
Tests default configuration data type.
File
-
core/
tests/ Drupal/ KernelTests/ Core/ Config/ DefaultConfigTest.php, line 65
Class
- DefaultConfigTest
- Tests that default configuration provided by all modules matches schema.
Namespace
Drupal\KernelTests\Core\ConfigCode
public function testDefaultConfig() {
$typed_config = \Drupal::service('config.typed');
// Create a configuration storage with access to default configuration in
// every module, profile and theme.
$default_config_storage = new TestInstallStorage();
foreach ($default_config_storage->listAll() as $config_name) {
if (in_array($config_name, $this->toSkip)) {
continue;
}
$data = $default_config_storage->read($config_name);
$this->assertConfigSchema($typed_config, $config_name, $data);
}
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.