comparison proxy_cache_revalidate.t @ 974:882267679006

Tests: simplified parallel modifications in tests. Mail tests were simplified in c227348453db.
author Andrey Zelenkov <zelenkov@nginx.com>
date Tue, 12 Jul 2016 17:39:03 +0300
parents e9064d691790
children 196d33c2bb45
comparison
equal deleted inserted replaced
973:7d7aef8b9f3a 974:882267679006
38 keys_zone=one:1m; 38 keys_zone=one:1m;
39 39
40 proxy_cache_revalidate on; 40 proxy_cache_revalidate on;
41 41
42 server { 42 server {
43 listen 127.0.0.1:%%PORT_0%%; 43 listen 127.0.0.1:8080;
44 server_name localhost; 44 server_name localhost;
45 45
46 location / { 46 location / {
47 proxy_pass http://127.0.0.1:%%PORT_1%%; 47 proxy_pass http://127.0.0.1:8081;
48 proxy_cache one; 48 proxy_cache one;
49 49
50 proxy_cache_valid 200 404 2s; 50 proxy_cache_valid 200 404 2s;
51 51
52 add_header X-Cache-Status $upstream_cache_status; 52 add_header X-Cache-Status $upstream_cache_status;
53 } 53 }
54 } 54 }
55 55
56 server { 56 server {
57 listen 127.0.0.1:%%PORT_1%%; 57 listen 127.0.0.1:8081;
58 server_name localhost; 58 server_name localhost;
59 59
60 location / { } 60 location / { }
61 location /etag/ { 61 location /etag/ {
62 proxy_pass http://127.0.0.1:%%PORT_1%%/; 62 proxy_pass http://127.0.0.1:8081/;
63 proxy_hide_header Last-Modified; 63 proxy_hide_header Last-Modified;
64 } 64 }
65 location /201 { 65 location /201 {
66 add_header Last-Modified "Mon, 02 Mar 2015 17:20:58 GMT"; 66 add_header Last-Modified "Mon, 02 Mar 2015 17:20:58 GMT";
67 add_header Cache-Control "max-age=1"; 67 add_header Cache-Control "max-age=1";