function AttributeClassDiscoveryCachedTest::setUp
Same name and namespace in other branches
- 10 core/tests/Drupal/Tests/Component/Plugin/Attribute/AttributeClassDiscoveryCachedTest.php \Drupal\Tests\Component\Plugin\Attribute\AttributeClassDiscoveryCachedTest::setUp()
File
-
core/
tests/ Drupal/ Tests/ Component/ Plugin/ Attribute/ AttributeClassDiscoveryCachedTest.php, line 21
Class
- AttributeClassDiscoveryCachedTest
- @coversDefaultClass <a href="/api/drupal/core%21lib%21Drupal%21Component%21Plugin%21Discovery%21AttributeClassDiscovery.php/class/AttributeClassDiscovery/11.x" title="Defines a discovery mechanism to find plugins with attributes." class="local">\Drupal\Component\Plugin\Discovery\AttributeClassDiscovery</a> @group Attribute @runTestsInSeparateProcesses
Namespace
Drupal\Tests\Component\Plugin\AttributeCode
protected function setUp() : void {
parent::setUp();
// Ensure FileCacheFactory::DISABLE_CACHE is *not* set, since we're testing
// integration with the file cache.
FileCacheFactory::setConfiguration([]);
// Ensure that FileCacheFactory has a prefix.
FileCacheFactory::setPrefix('prefix');
// Normally the attribute classes would be autoloaded.
include_once __DIR__ . '/Fixtures/CustomPlugin.php';
include_once __DIR__ . '/Fixtures/Plugins/PluginNamespace/AttributeDiscoveryTest1.php';
}
Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.