File tree Expand file tree Collapse file tree 1 file changed +15
-1
lines changed
Expand file tree Collapse file tree 1 file changed +15
-1
lines changed Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ use Test::Nginx;
2222select STDERR ; $| = 1;
2323select STDOUT ; $| = 1;
2424
25- my $t = Test::Nginx-> new()-> has(qw/ http proxy cache rewrite/ )-> plan(19 );
25+ my $t = Test::Nginx-> new()-> has(qw/ http proxy cache rewrite/ )-> plan(20 );
2626
2727$t -> write_file_expand(' nginx.conf' , <<'EOF' );
2828
@@ -74,6 +74,12 @@ http {
7474 return 204;
7575 }
7676
77+ location /cache-control-overflow {
78+ # sufficiently large for 32-bit and 64-bit representations
79+ add_header Cache-Control max-age=9223372036854775808;
80+ return 204;
81+ }
82+
7783 location /x-accel-expires {
7884 add_header X-Accel-Expires 60;
7985 return 204;
@@ -191,6 +197,14 @@ $t->run();
191197
192198like(get(' /expires' ), qr / HIT/ , ' expires' );
193199like(get(' /cache-control' ), qr / HIT/ , ' cache-control' );
200+
201+ TODO: {
202+ local $TODO = ' not yet' unless $t -> has_version(' 1.29.2' );
203+
204+ like(get(' /cache-control-overflow' ), qr / HIT/ , ' cache-control overflow' );
205+
206+ }
207+
194208like(get(' /x-accel-expires' ), qr / HIT/ , ' x-accel-expires' );
195209like(get(' /x-accel-expires-at' ), qr / EXPIRED/ , ' x-accel-expires at' );
196210
You can’t perform that action at this time.
0 commit comments