~ubuntu-branches/ubuntu/hardy/lighttpd/hardy

« back to all changes in this revision

Viewing changes to tests/cachable.t

  • Committer: Bazaar Package Importer
  • Author(s): Soren Hansen
  • Date: 2007-09-05 09:30:15 UTC
  • mfrom: (1.1.8 upstream)
  • Revision ID: james.westby@ubuntu.com-20070905093015-pm98jekbu9ylcd3w
Tags: 1.4.17-1ubuntu1
* Merge from Debian unstable, remaining changes:
  - Update maintainer field in debian/control.
  - Build against libgamin-dev rather than libfam-dev (fixes a warning
    during startup)
  - Make sure that upgrades succeed, even if we can't restart lighttpd.
  - Clean environment in init.d script.

Show diffs side-by-side

added added

removed removed

Lines of Context:
8
8
 
9
9
use strict;
10
10
use IO::Socket;
11
 
use Test::More tests => 12;
 
11
use Test::More tests => 13;
12
12
use LightyTest;
13
13
 
14
14
my $tf = LightyTest->new();
108
108
$t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 412 } ];
109
109
ok($tf->handle_http($t) == 0, 'Conditional GET - ETag + Last-Modified + overlong timestamp');
110
110
 
 
111
$t->{REQUEST}  = ( <<EOF
 
112
GET / HTTP/1.0
 
113
If-None-Match: $etag
 
114
Host: etag.example.org
 
115
EOF
 
116
 );
 
117
$t->{RESPONSE} = [ { 'HTTP-Protocol' => 'HTTP/1.0', 'HTTP-Status' => 200 } ];
 
118
ok($tf->handle_http($t) == 0, 'Conditional GET - ETag + disabled etags on server side');
 
119
 
111
120
ok($tf->stop_proc == 0, "Stopping lighttpd");
112
121