summaryrefslogtreecommitdiff
path: root/includes/tests/bootstrap.test
diff options
context:
space:
mode:
authorDries Buytaert <dries@buytaert.net>2008-07-17 21:10:39 +0000
committerDries Buytaert <dries@buytaert.net>2008-07-17 21:10:39 +0000
commitfb3b6d13b8e9f594b248b0485af0c9429d3c7ee1 (patch)
treeb55083b80df40a44639bad4bd42746a6e34ed2a2 /includes/tests/bootstrap.test
parent57fe5103daf5db65cd43f309e0f22f5c4781605d (diff)
downloadbrdo-fb3b6d13b8e9f594b248b0485af0c9429d3c7ee1.tar.gz
brdo-fb3b6d13b8e9f594b248b0485af0c9429d3c7ee1.tar.bz2
- Patch #231190 by eli, mfb: page cache didn't work with HEAD requests.
Diffstat (limited to 'includes/tests/bootstrap.test')
-rw-r--r--includes/tests/bootstrap.test26
1 files changed, 26 insertions, 0 deletions
diff --git a/includes/tests/bootstrap.test b/includes/tests/bootstrap.test
index 4b2cf3089..3bb197aae 100644
--- a/includes/tests/bootstrap.test
+++ b/includes/tests/bootstrap.test
@@ -81,3 +81,29 @@ class BootstrapIPAddressTestCase extends DrupalWebTestCase {
);
}
}
+
+class BootstrapPageCacheTestCase extends DrupalWebTestCase {
+
+ /**
+ * Implementation of getInfo().
+ */
+ function getInfo() {
+ return array(
+ 'name' => t('Page cache test'),
+ 'description' => t('Enable the page cache, submit a HEAD request and examine headers.'),
+ 'group' => t('Bootstrap')
+ );
+ }
+
+ /**
+ * Enable cache and examine HTTP headers.
+ */
+ function testPageCache() {
+ global $base_url;
+ variable_set('cache', 1);
+ // Retrieve the front page, which has already been cached by $this->curlConnect();
+ $this->drupalHead($base_url);
+ $this->assertText('ETag: ', t('Verify presence of ETag header indicating that page caching is enabled.'));
+ }
+
+}