You are here

function authcache_backend_test_boot in Authenticated User Page Caching (Authcache) 7.2

Implements hook_boot().

File

tests/authcache_backend_test.module, line 11
Provides a stub cache backend for testing purposes.

Code

function authcache_backend_test_boot() {
  $info = HookStub::record(__FUNCTION__, func_get_args());
  if ($info === FALSE) {
    return;
  }
  if (!isset($info['backends'])) {
    $module = isset($info[0]) ? $info[0] : 'authcache_backend_test';
    $vary_header = isset($info[1]) ? $info[1] : 'Cookie';
    $key = isset($info[2]) ? $info[2] : FALSE;
    $info['backends'] = array(
      array(
        $module,
        $vary_header,
        $key,
      ),
    );
  }
  foreach ($info['backends'] as $args) {
    list($module, $vary_header, $initial_key) = $args;
    authcache_backend_init($module, $vary_header, $initial_key);
  }
}