Mercurial > hg > nginx-tests
comparison access_log.t @ 568:907e89fba9c3
Tests: removed TODO and try_run() checks for legacy versions.
author | Sergey Kandaurov <pluknet@nginx.com> |
---|---|
date | Sun, 03 May 2015 12:45:09 +0300 |
parents | 43e05ac6c23c |
children | e9f48f1e905b |
comparison
equal
deleted
inserted
replaced
567:22bade4c7e12 | 568:907e89fba9c3 |
---|---|
19 ############################################################################### | 19 ############################################################################### |
20 | 20 |
21 select STDERR; $| = 1; | 21 select STDERR; $| = 1; |
22 select STDOUT; $| = 1; | 22 select STDOUT; $| = 1; |
23 | 23 |
24 my $t = Test::Nginx->new()->has(qw/http rewrite/) | 24 my $t = Test::Nginx->new()->has(qw/http rewrite/)->plan(9) |
25 ->write_file_expand('nginx.conf', <<'EOF'); | 25 ->write_file_expand('nginx.conf', <<'EOF'); |
26 | 26 |
27 %%TEST_GLOBALS%% | 27 %%TEST_GLOBALS%% |
28 | 28 |
29 daemon off; | 29 daemon off; |
89 } | 89 } |
90 } | 90 } |
91 | 91 |
92 EOF | 92 EOF |
93 | 93 |
94 $t->try_run('no access_log if')->plan(9); | 94 $t->run(); |
95 | 95 |
96 ############################################################################### | 96 ############################################################################### |
97 | 97 |
98 http_get('/combined'); | 98 http_get('/combined'); |
99 http_get('/combined/off'); | 99 http_get('/combined/off'); |
182 is($log, $exp_complex, 'if with complex value'); | 182 is($log, $exp_complex, 'if with complex value'); |
183 | 183 |
184 | 184 |
185 # buffer created with false "if" is not reused among multiple access_log | 185 # buffer created with false "if" is not reused among multiple access_log |
186 | 186 |
187 TODO: { | |
188 local $TODO = 'not yet' unless $t->has_version('1.7.5'); | |
189 | |
190 $log = $t->read_file('/noreuse.log'); | 187 $log = $t->read_file('/noreuse.log'); |
191 is($log, "/filtered/noreuse1/good:200\n/filtered/noreuse2/good:200\n", | 188 is($log, "/filtered/noreuse1/good:200\n/filtered/noreuse2/good:200\n", |
192 'log filtering with buffering'); | 189 'log filtering with buffering'); |
193 | 190 |
194 } | |
195 | |
196 | 191 |
197 # multiple logs in a same location | 192 # multiple logs in a same location |
198 | 193 |
199 $log = $t->read_file('multi1.log'); | 194 $log = $t->read_file('multi1.log'); |
200 is($log, "/multi:200\n", 'multiple logs 1'); | 195 is($log, "/multi:200\n", 'multiple logs 1'); |