function CacheCollectorTest::setUp
Overrides UnitTestCase::setUp
File
- 
              core/tests/ Drupal/ Tests/ Core/ Cache/ CacheCollectorTest.php, line 54 
Class
- CacheCollectorTest
- @coversDefaultClass \Drupal\Core\Cache\CacheCollector[[api-linebreak]] @group Cache
Namespace
Drupal\Tests\Core\CacheCode
protected function setUp() : void {
  parent::setUp();
  $this->cacheBackend = $this->createMock('Drupal\\Core\\Cache\\CacheBackendInterface');
  $this->cacheTagsInvalidator = $this->createMock('Drupal\\Core\\Cache\\CacheTagsInvalidatorInterface');
  $this->lock = $this->createMock('Drupal\\Core\\Lock\\LockBackendInterface');
  $this->cid = $this->randomMachineName();
  $this->collector = new CacheCollectorHelper($this->cid, $this->cacheBackend, $this->lock);
  $this->getContainerWithCacheTagsInvalidator($this->cacheTagsInvalidator);
}Buggy or inaccurate documentation? Please file an issue. Need support? Need help programming? Connect with the Drupal community.
