You are here

protected function DatabaseStorageTest::setUp in Drupal 10

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

File

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

Class

DatabaseStorageTest
Tests DatabaseStorage operations.

Namespace

Drupal\KernelTests\Core\Config\Storage

Code

protected function setUp() : void {
  parent::setUp();
  $this->storage = new DatabaseStorage($this->container
    ->get('database'), 'config');
  $this->invalidStorage = new DatabaseStorage($this->container
    ->get('database'), 'invalid');

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