Beispiel #1
0
 /**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     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', array());
 }
 /**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     parent::setUp();
     $this->storage = new StorageReplaceDataWrapper($this->container->get('config.storage'));
     // ::listAll() verifications require other configuration data to exist.
     $this->storage->write('system.performance', array());
     $this->storage->replaceData('system.performance', array('foo' => 'bar'));
 }
Beispiel #3
0
 /**
  * {@inheritdoc}
  */
 protected function setUp()
 {
     parent::setUp();
     // Create a directory.
     $this->directory = PublicStream::basePath() . '/config';
     $this->storage = new FileStorage($this->directory);
     $this->invalidStorage = new FileStorage($this->directory . '/nonexisting');
     // FileStorage::listAll() requires other configuration data to exist.
     $this->storage->write('system.performance', $this->config('system.performance')->get());
     $this->storage->write('core.extension', array('module' => array()));
 }
Beispiel #4
0
 /**
  * {@inheritdoc}
  */
 public function containerBuild(ContainerBuilder $container)
 {
     parent::containerBuild($container);
     // Use the regular database cache backend to aid testing.
     $container->register('cache_factory', 'Drupal\\Core\\Cache\\DatabaseBackendFactory')->addArgument(new Reference('database'))->addArgument(new Reference('cache_tags.invalidator.checksum'));
 }