public function ConfigTest::setUp in Zircon Profile 8
Same name in this branch
- 8 core/tests/Drupal/Tests/Core/Config/ConfigTest.php \Drupal\Tests\Core\Config\ConfigTest::setUp()
- 8 core/modules/system/src/Tests/File/ConfigTest.php \Drupal\system\Tests\File\ConfigTest::setUp()
Same name and namespace in other branches
- 8.0 core/tests/Drupal/Tests/Core/Config/ConfigTest.php \Drupal\Tests\Core\Config\ConfigTest::setUp()
Overrides UnitTestCase::setUp
File
- core/
tests/ Drupal/ Tests/ Core/ Config/ ConfigTest.php, line 61 - Contains \Drupal\Tests\Core\Config\ConfigTest.
Class
- ConfigTest
- Tests the Config.
Namespace
Drupal\Tests\Core\ConfigCode
public function setUp() {
$this->storage = $this
->getMock('Drupal\\Core\\Config\\StorageInterface');
$this->eventDispatcher = $this
->getMock('Symfony\\Component\\EventDispatcher\\EventDispatcherInterface');
$this->typedConfig = $this
->getMock('\\Drupal\\Core\\Config\\TypedConfigManagerInterface');
$this->config = new Config('config.test', $this->storage, $this->eventDispatcher, $this->typedConfig);
$this->cacheTagsInvalidator = $this
->getMock('Drupal\\Core\\Cache\\CacheTagsInvalidatorInterface');
$container = new ContainerBuilder();
$container
->set('cache_tags.invalidator', $this->cacheTagsInvalidator);
\Drupal::setContainer($container);
}