protected function StorageTestBase::setUp in Service Container 7.2
Same name and namespace in other branches
- 7 lib/Drupal/service_container/Tests/KeyValue/StorageTestBase.php \Drupal\service_container\Tests\KeyValue\StorageTestBase::setUp()
Overrides ServiceContainerIntegrationTestBase::setUp
2 calls to StorageTestBase::setUp()
- DatabaseStorageExpirableTest::setUp in lib/
Drupal/ service_container/ Tests/ KeyValue/ DatabaseStorageExpirableTest.php - MemoryStorageTest::setUp in lib/
Drupal/ service_container/ Tests/ KeyValue/ MemoryStorageTest.php
2 methods override StorageTestBase::setUp()
- DatabaseStorageExpirableTest::setUp in lib/
Drupal/ service_container/ Tests/ KeyValue/ DatabaseStorageExpirableTest.php - MemoryStorageTest::setUp in lib/
Drupal/ service_container/ Tests/ KeyValue/ MemoryStorageTest.php
File
- lib/
Drupal/ service_container/ Tests/ KeyValue/ StorageTestBase.php, line 45 - Contains Drupal\service_container\Tests\KeyValue\StorageTestBase.
Class
- StorageTestBase
- Base class for testing key-value storages.
Namespace
Drupal\service_container\Tests\KeyValueCode
protected function setUp() {
$args = func_get_args();
parent::setUp($args);
// Define two data collections,
$this->collections = array(
0 => 'zero',
1 => 'one',
);
// Create several objects for testing.
for ($i = 0; $i <= 5; $i++) {
$this->objects[$i] = (object) array(
'key1' => $this
->randomString(),
'key2' => $this
->randomString(),
);
}
}