You are here

function authcache_test_authcache_cookie in Authenticated User Page Caching (Authcache) 7.2

Implements hook_authcache_cookie().

2 string references to 'authcache_test_authcache_cookie'
AuthcacheCookiesTestCase::testCookieHooks in ./authcache.test
Verify that hook_authcache_cookie is called on every request.
AuthcacheWebTestCase::resetTestVariables in ./authcache.test
Reset the variables used for communicating to authcache_test module.

File

tests/authcache_test.module, line 427
Mock module to aid in testing authcache.module.

Code

function authcache_test_authcache_cookie($account) {

  // Do not record anything resulting from test user login/logout
  if (variable_get('authcache_test_record')) {
    variable_set('authcache_test_authcache_cookie', $account->uid);
  }
  if ($cookie = variable_get('authcache_test_cookie')) {
    return $cookie;
  }
}