You are here

MemcacheBackendUnitTest.php in Zircon Profile 8

Same filename and directory in other branches
  1. 8.0 modules/memcache/src/Tests/MemcacheBackendUnitTest.php

File

modules/memcache/src/Tests/MemcacheBackendUnitTest.php
View source
<?php

/**
 * @file
 * Contains \Drupal\memcache\Tests\MemcacheBackendUnitTest.
 */
namespace Drupal\memcache\Tests;

use Drupal\memcache\MemcacheBackendFactory;
use Drupal\system\Tests\Cache\GenericCacheBackendUnitTestBase;

/**
 * Tests the MemcacheBackend.
 *
 * @group memcache
 */
class MemcacheBackendUnitTest extends GenericCacheBackendUnitTestBase {

  /**
   * Modules to enable.
   *
   * @var array
   */
  public static $modules = [
    'system',
    'memcache',
  ];

  /**
   * Creates a new instance of DatabaseBackend.
   *
   * @return \Drupal\memcache\MemcacheBackend
   *   A new MemcacheBackend object.
   */
  protected function createCacheBackend($bin) {
    $factory = new MemcacheBackendFactory($this->container
      ->get('lock'), $this->container
      ->get('settings'), $this->container
      ->get('memcache.factory'), $this->container
      ->get('cache_tags.invalidator.checksum'));
    return $factory
      ->get($bin);
  }

}

Classes

Namesort descending Description
MemcacheBackendUnitTest Tests the MemcacheBackend.