summaryrefslogtreecommitdiff
path: root/tests/request.t
diff options
context:
space:
mode:
Diffstat (limited to 'tests/request.t')
-rwxr-xr-xtests/request.t10
1 files changed, 9 insertions, 1 deletions
diff --git a/tests/request.t b/tests/request.t
index cbc90e41..8ece7218 100755
--- a/tests/request.t
+++ b/tests/request.t
@@ -8,7 +8,7 @@ BEGIN {
use strict;
use IO::Socket;
-use Test::More tests => 40;
+use Test::More tests => 41;
use LightyTest;
my $tf = LightyTest->new();
@@ -381,5 +381,13 @@ EOF
$t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 304, 'Content-Type' => 'text/html' } ];
ok($tf->handle_http($t) == 0, 'If-Modified-Since');
+$t->{REQUEST} = ( <<EOF
+GET /index.html HTTP/1.0
+If-Modified-Since: Sun, 01 Jan 2100 00:00:02 GMT
+EOF
+ );
+$t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 304, '-Content-Length' => '' } ];
+ok($tf->handle_http($t) == 0, 'Status 304 has no Content-Length (#1002)');
+
ok($tf->stop_proc == 0, "Stopping lighttpd");