summaryrefslogtreecommitdiff
path: root/tests/cachable.t
diff options
context:
space:
mode:
authorMarcus Rückert <darix@opensu.se>2007-08-27 21:48:53 +0000
committerMarcus Rückert <darix@opensu.se>2007-08-27 21:48:53 +0000
commitea872bea37dc30c8da4c1ff5f5a4966f5ff73362 (patch)
tree062516574a408c3ca56ee9572e98b075f481acf1 /tests/cachable.t
parent74c303a7b14fce00de856c0a138a10cf866b828c (diff)
downloadlighttpd1.4-ea872bea37dc30c8da4c1ff5f5a4966f5ff73362.tar.gz
lighttpd1.4-ea872bea37dc30c8da4c1ff5f5a4966f5ff73362.zip
- added testcase for bug #1322
git-svn-id: svn://svn.lighttpd.net/lighttpd/branches/lighttpd-1.4.x@1968 152afb58-edef-0310-8abb-c4023f1b3aa9
Diffstat (limited to 'tests/cachable.t')
-rwxr-xr-xtests/cachable.t11
1 files changed, 10 insertions, 1 deletions
diff --git a/tests/cachable.t b/tests/cachable.t
index 9dc11211..0d1e1b42 100755
--- a/tests/cachable.t
+++ b/tests/cachable.t
@@ -8,7 +8,7 @@ BEGIN {
use strict;
use IO::Socket;
-use Test::More tests => 12;
+use Test::More tests => 13;
use LightyTest;
my $tf = LightyTest->new();
@@ -108,5 +108,14 @@ EOF
$t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 412 } ];
ok($tf->handle_http($t) == 0, 'Conditional GET - ETag + Last-Modified + overlong timestamp');
+$t->{REQUEST} = ( <<EOF
+GET / HTTP/1.0
+If-None-Match: $etag
+Host: etag.example.org
+EOF
+ );
+$t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 200 } ];
+ok($tf->handle_http($t) == 0, 'Conditional GET - ETag + disabled etags on server side');
+
ok($tf->stop_proc == 0, "Stopping lighttpd");