@@ 361-371 (lines=11) @@ | ||
358 | self::assertSame('testing:bar', $barRegion->getCache()->getNamespace()); |
|
359 | } |
|
360 | ||
361 | public function testBuildsDefaultCacheRegionFromGenericCacheRegion() |
|
362 | { |
|
363 | /* @var $cache \Doctrine\Common\Cache\Cache */ |
|
364 | $cache = $this->createMock(Cache::class); |
|
365 | $factory = new DefaultCacheFactory($this->regionsConfig, $cache); |
|
366 | ||
367 | $barCache = new CacheMetadata(CacheUsage::READ_ONLY, 'bar'); |
|
368 | $barRegion = $factory->getRegion($barCache); |
|
369 | ||
370 | self::assertInstanceOf(DefaultRegion::class, $barRegion); |
|
371 | } |
|
372 | ||
373 | public function testBuildsMultiGetCacheRegionFromGenericCacheRegion() |
|
374 | { |
|
@@ 373-383 (lines=11) @@ | ||
370 | self::assertInstanceOf(DefaultRegion::class, $barRegion); |
|
371 | } |
|
372 | ||
373 | public function testBuildsMultiGetCacheRegionFromGenericCacheRegion() |
|
374 | { |
|
375 | /* @var $cache \Doctrine\Common\Cache\CacheProvider */ |
|
376 | $cache = $this->getMockForAbstractClass(CacheProvider::class); |
|
377 | $factory = new DefaultCacheFactory($this->regionsConfig, $cache); |
|
378 | ||
379 | $barCache = new CacheMetadata(CacheUsage::READ_ONLY, 'bar'); |
|
380 | $barRegion = $factory->getRegion($barCache); |
|
381 | ||
382 | self::assertInstanceOf(DefaultMultiGetRegion::class, $barRegion); |
|
383 | } |
|
384 | ||
385 | } |
|
386 |