protected function GarbageCollectionTest::setUp

Sets up unit test environment.

Unlike Drupal\simpletest\WebTestBase::setUp(), UnitTestBase::setUp() does not install modules because tests are performed without accessing the database. Any required files must be explicitly included by the child class setUp() method.

Overrides UnitTestBase::setUp

File

drupal/core/modules/system/lib/Drupal/system/Tests/KeyValueStore/GarbageCollectionTest.php, line 27
Contains Drupal\system\Tests\KeyValueStore\GarbageCollectionTest.

Class

GarbageCollectionTest
Tests garbage collection for DatabaseStorageExpirable.

Namespace

Drupal\system\Tests\KeyValueStore

Code

protected function setUp() {
  parent::setUp();
  module_load_install('system');
  $schema = system_schema();
  db_create_table('key_value_expire', $schema['key_value_expire']);
}