summaryrefslogtreecommitdiff
path: root/modules/simpletest
diff options
context:
space:
mode:
Diffstat (limited to 'modules/simpletest')
-rw-r--r--modules/simpletest/tests/bootstrap.test10
-rw-r--r--modules/simpletest/tests/session.test2
2 files changed, 6 insertions, 6 deletions
diff --git a/modules/simpletest/tests/bootstrap.test b/modules/simpletest/tests/bootstrap.test
index 9ab2c8382..043cc4a3a 100644
--- a/modules/simpletest/tests/bootstrap.test
+++ b/modules/simpletest/tests/bootstrap.test
@@ -105,7 +105,7 @@ class BootstrapPageCacheTestCase extends DrupalWebTestCase {
* Test support for requests containing If-Modified-Since and If-None-Match headers.
*/
function testConditionalRequests() {
- variable_set('cache', CACHE_NORMAL);
+ variable_set('cache', 1);
// Fill the cache.
$this->drupalGet('');
@@ -143,7 +143,7 @@ class BootstrapPageCacheTestCase extends DrupalWebTestCase {
* Test cache headers.
*/
function testPageCache() {
- variable_set('cache', CACHE_NORMAL);
+ variable_set('cache', 1);
// Fill the cache.
$this->drupalGet('system-test/set-header', array('query' => array('name' => 'Foo', 'value' => 'bar')));
@@ -187,7 +187,7 @@ class BootstrapPageCacheTestCase extends DrupalWebTestCase {
* mod_deflate Apache module.
*/
function testPageCompression() {
- variable_set('cache', CACHE_NORMAL);
+ variable_set('cache', 1);
// Fill the cache and verify that output is compressed.
$this->drupalGet('', array(), array('Accept-Encoding: gzip,deflate'));
@@ -280,14 +280,14 @@ class HookBootExitTestCase extends DrupalWebTestCase {
*/
function testHookBootExit() {
// Test with cache disabled. Boot and exit should always fire.
- variable_set('cache', CACHE_DISABLED);
+ variable_set('cache', 0);
$this->drupalGet('');
$calls = 1;
$this->assertEqual(db_query('SELECT COUNT(*) FROM {watchdog} WHERE type = :type AND message = :message', array(':type' => 'system_test', ':message' => 'hook_boot'))->fetchField(), $calls, t('hook_boot called with disabled cache.'));
$this->assertEqual(db_query('SELECT COUNT(*) FROM {watchdog} WHERE type = :type AND message = :message', array(':type' => 'system_test', ':message' => 'hook_exit'))->fetchField(), $calls, t('hook_exit called with disabled cache.'));
// Test with normal cache. Boot and exit should be called.
- variable_set('cache', CACHE_NORMAL);
+ variable_set('cache', 1);
$this->drupalGet('');
$calls++;
$this->assertEqual(db_query('SELECT COUNT(*) FROM {watchdog} WHERE type = :type AND message = :message', array(':type' => 'system_test', ':message' => 'hook_boot'))->fetchField(), $calls, t('hook_boot called with normal cache.'));
diff --git a/modules/simpletest/tests/session.test b/modules/simpletest/tests/session.test
index 7caecbe98..1b74405fd 100644
--- a/modules/simpletest/tests/session.test
+++ b/modules/simpletest/tests/session.test
@@ -140,7 +140,7 @@ class SessionTestCase extends DrupalWebTestCase {
$this->assertSessionEmpty(TRUE);
// The same behavior is expected when caching is enabled.
- variable_set('cache', CACHE_NORMAL);
+ variable_set('cache', 1);
$this->drupalGet('');
$this->assertSessionCookie(FALSE);
$this->assertSessionEmpty(TRUE);