You are here

public function ConfigEntityImportTest::testConfigUpdateImport in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/system/tests/src/Kernel/Entity/ConfigEntityImportTest.php \Drupal\Tests\system\Kernel\Entity\ConfigEntityImportTest::testConfigUpdateImport()

Runs test methods for each module within a single test run.

File

core/modules/system/tests/src/Kernel/Entity/ConfigEntityImportTest.php, line 40

Class

ConfigEntityImportTest
Tests ConfigEntity importing.

Namespace

Drupal\Tests\system\Kernel\Entity

Code

public function testConfigUpdateImport() {
  $this
    ->installConfig([
    'action',
    'block',
    'filter',
    'image',
  ]);
  $this->container
    ->get('theme_installer')
    ->install([
    'bartik',
  ]);
  $config_storage = $this->container
    ->get('config.storage');

  // Ensure the 'system.site' config.
  $config_storage
    ->write('system.site', [
    'uuid' => (new Php())
      ->generate(),
  ]);
  $this
    ->copyConfig($config_storage, $this->container
    ->get('config.storage.sync'));
  $this
    ->doActionUpdate();
  $this
    ->doBlockUpdate();
  $this
    ->doFilterFormatUpdate();
  $this
    ->doImageStyleUpdate();
  $this
    ->doSearchPageUpdate();
  $this
    ->doThirdPartySettingsUpdate();
}