You are here

protected function StorageReplaceDataWrapperTest::setUp in Drupal 9

Same name and namespace in other branches
  1. 8 core/tests/Drupal/KernelTests/Core/Config/Storage/StorageReplaceDataWrapperTest.php \Drupal\KernelTests\Core\Config\Storage\StorageReplaceDataWrapperTest::setUp()
  2. 10 core/tests/Drupal/KernelTests/Core/Config/Storage/StorageReplaceDataWrapperTest.php \Drupal\KernelTests\Core\Config\Storage\StorageReplaceDataWrapperTest::setUp()

Overrides KernelTestBase::setUp

File

core/tests/Drupal/KernelTests/Core/Config/Storage/StorageReplaceDataWrapperTest.php, line 18

Class

StorageReplaceDataWrapperTest
Tests StorageReplaceDataWrapper operations.

Namespace

Drupal\KernelTests\Core\Config\Storage

Code

protected function setUp() : void {
  parent::setUp();
  $this->storage = new StorageReplaceDataWrapper($this->container
    ->get('config.storage'));

  // ::listAll() verifications require other configuration data to exist.
  $this->storage
    ->write('system.performance', []);
  $this->storage
    ->replaceData('system.performance', [
    'foo' => 'bar',
  ]);
}