Version 1
[yaffs-website] / web / core / tests / Drupal / KernelTests / Core / Cache / MemoryBackendTest.php
1 <?php
2
3 namespace Drupal\KernelTests\Core\Cache;
4
5 use Drupal\Core\Cache\MemoryBackend;
6
7 /**
8  * Unit test of the memory cache backend using the generic cache unit test base.
9  *
10  * @group Cache
11  */
12 class MemoryBackendTest extends GenericCacheBackendUnitTestBase {
13
14   /**
15    * Creates a new instance of MemoryBackend.
16    *
17    * @return
18    *   A new MemoryBackend object.
19    */
20   protected function createCacheBackend($bin) {
21     $backend = new MemoryBackend();
22     \Drupal::service('cache_tags.invalidator')->addInvalidator($backend);
23     return $backend;
24   }
25
26 }