You are here

protected function AuthcacheWebTestCase::setupConfig in Authenticated User Page Caching (Authcache) 7.2

Reset authcache configuration and test variables.

14 calls to AuthcacheWebTestCase::setupConfig()
AuthcacheAnonymousKeysTestCase::testCustomKeyGenerator in ./authcache.test
Test custom key generator.
AuthcacheAnonymousKeysTestCase::testDefaultAnonymousKey in ./authcache.test
Test default anonymous key.
AuthcacheAuthenticatedKeysTestCase::testDifferentKeysForDifferentRoles in ./authcache.test
Test different keys for different roles.
AuthcacheAuthenticatedKeysTestCase::testHookAuthcacheKeyProperties in ./authcache.test
Test custom key properties.
AuthcacheAuthenticatedKeysTestCase::testKeyAbbreviation in ./authcache.test
Test key abbreviation (variable authcache_key_abbrev).

... See full list

File

./authcache.test, line 70
Tests for system.module.

Class

AuthcacheWebTestCase
Helper class for module test cases.

Code

protected function setupConfig($defaults = array()) {
  $settings = array(
    'authcache_frontcontroller_whitelist',
    'authcache_key_abbrev',
    'authcache_key_generator',
    'authcache_key_generator_keys',
    'authcacke_key_lifetime',
    'authcache_http200',
    'authcache_mimetype',
    'authcache_noajax',
    'authcache_pagecaching',
    'authcache_roles',
    'authcache_su',
  );
  foreach ($settings as $var) {
    variable_del($var);
  }
  foreach ($defaults as $var => $value) {
    variable_set($var, $value);
  }
}