diff --git a/core/lib/Drupal/Core/DrupalKernel.php b/core/lib/Drupal/Core/DrupalKernel.php index 25a0f4e96049b5d58c17ba271b8296bdc4ccdfbd..e8eb9cd18a3a8b65238c5708e5d75331def5f295 100644 --- a/core/lib/Drupal/Core/DrupalKernel.php +++ b/core/lib/Drupal/Core/DrupalKernel.php @@ -776,8 +776,7 @@ protected function moduleData($module) { // If a module is within a profile directory but specifies another // profile for testing, it needs to be found in the parent profile. - $settings = $this->getConfigStorage()->read('simpletest.settings'); - $parent_profile = !empty($settings['parent_profile']) ? $settings['parent_profile'] : NULL; + $parent_profile = Settings::get('test_parent_profile'); if ($parent_profile && !isset($profiles[$parent_profile])) { // In case both profile directories contain the same extension, the // actual profile always has precedence. diff --git a/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php b/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php index 717afc3be5d428da72edc1ebd0c4e142944beaf7..856d2e009c96e800d19b02b6c214940aaf4f8b3a 100644 --- a/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php +++ b/core/lib/Drupal/Core/Extension/ExtensionDiscovery.php @@ -233,7 +233,7 @@ public function setProfileDirectoriesFromSettings() { // distribution we need to include the profile of the parent site (in // which test runs are triggered). if (drupal_valid_test_ua() && !drupal_installation_attempted()) { - $testing_profile = \Drupal::config('simpletest.settings')->get('parent_profile'); + $testing_profile = Settings::get('test_parent_profile'); if ($testing_profile && $testing_profile != $profile) { $this->profileDirectories[] = drupal_get_path('profile', $testing_profile); } diff --git a/core/lib/Drupal/Core/Extension/ModuleExtensionList.php b/core/lib/Drupal/Core/Extension/ModuleExtensionList.php index c8f492bd4fe9ad5cdf4fc401bb0845fc7ac3e0af..e637c14fa0b9bab310d8ff9eae657c43c1ebc6ff 100644 --- a/core/lib/Drupal/Core/Extension/ModuleExtensionList.php +++ b/core/lib/Drupal/Core/Extension/ModuleExtensionList.php @@ -4,6 +4,7 @@ use Drupal\Core\Cache\CacheBackendInterface; use Drupal\Core\Config\ConfigFactoryInterface; +use Drupal\Core\Site\Settings; use Drupal\Core\State\StateInterface; use Drupal\Core\StringTranslation\StringTranslationTrait; @@ -111,7 +112,7 @@ protected function getProfileDirectories(ExtensionDiscovery $discovery) { // If a module is within a profile directory but specifies another // profile for testing, it needs to be found in the parent profile. - $parent_profile = $this->configFactory->get('simpletest.settings')->get('parent_profile'); + $parent_profile = Settings::get('test_parent_profile'); if ($parent_profile && !isset($profiles[$parent_profile])) { // In case both profile directories contain the same extension, the diff --git a/core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php b/core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php index 3f8a74326abb39e9609dd372bf961fc7aabb0d77..c085d4ec6bc2ed59cd0d3202bfec7c1146afdf95 100644 --- a/core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php +++ b/core/lib/Drupal/Core/Test/FunctionalTestSetupTrait.php @@ -107,7 +107,7 @@ protected function prepareSettings() { ]; // Add the parent profile's search path to the child site's search paths. // @see \Drupal\Core\Extension\ExtensionDiscovery::getProfileDirectories() - $settings['conf']['simpletest.settings']['parent_profile'] = (object) [ + $settings['setting']['test_parent_profile'] = (object) [ 'value' => $this->originalProfile, 'required' => TRUE, ]; @@ -137,7 +137,7 @@ protected function prepareSettings() { $yaml = new SymfonyYaml(); $content = file_get_contents($directory . '/services.yml'); $services = $yaml->parse($content); - $services['services']['simpletest.config_schema_checker'] = [ + $services['services']['testing.config_schema_checker'] = [ 'class' => ConfigSchemaChecker::class, 'arguments' => ['@config.typed', $this->getConfigSchemaExclusions()], 'tags' => [['name' => 'event_subscriber']], diff --git a/core/modules/simpletest/src/KernelTestBase.php b/core/modules/simpletest/src/KernelTestBase.php index 03d4784ad606a2fe42486a9ad61379d524621118..caab5335b590b537e471d99a2c683f61740f696d 100644 --- a/core/modules/simpletest/src/KernelTestBase.php +++ b/core/modules/simpletest/src/KernelTestBase.php @@ -351,7 +351,7 @@ public function containerBuild(ContainerBuilder $container) { if ($this->strictConfigSchema) { $container - ->register('simpletest.config_schema_checker', ConfigSchemaChecker::class) + ->register('testing.config_schema_checker', ConfigSchemaChecker::class) ->addArgument(new Reference('config.typed')) ->addArgument($this->getConfigSchemaExclusions()) ->addTag('event_subscriber'); diff --git a/core/tests/Drupal/KernelTests/KernelTestBase.php b/core/tests/Drupal/KernelTests/KernelTestBase.php index e2d1c17f3bf71366c083e91fdfc81c01dd504ce8..fd26d08a142e039fd5144867ff79dee87c032fe9 100644 --- a/core/tests/Drupal/KernelTests/KernelTestBase.php +++ b/core/tests/Drupal/KernelTests/KernelTestBase.php @@ -532,7 +532,7 @@ public function register(ContainerBuilder $container) { if ($this->strictConfigSchema) { $container - ->register('simpletest.config_schema_checker', ConfigSchemaChecker::class) + ->register('testing.config_schema_checker', ConfigSchemaChecker::class) ->addArgument(new Reference('config.typed')) ->addArgument($this->getConfigSchemaExclusions()) ->addTag('event_subscriber');