summaryrefslogtreecommitdiff
path: root/modules/simpletest/tests
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2010-05-12 08:26:15 +0000
committerDries Buytaert <dries@buytaert.net>2010-05-12 08:26:15 +0000
commit47653eae18f8ee69194438cdba0bd0baaffcf6c8 (patch)
tree64f32783c5169246d2b3b618825e742f31961838 /modules/simpletest/tests
parenta60a608ed86e8971d77760e9df3a0932efc88d00 (diff)
downloadbrdo-47653eae18f8ee69194438cdba0bd0baaffcf6c8.tar.gz
brdo-47653eae18f8ee69194438cdba0bd0baaffcf6c8.tar.bz2
- Patch #730046 by pwolanin, Damien Tournoud: performance settings page is inconsistent.
Diffstat (limited to 'modules/simpletest/tests')
-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);