comparison proxy_force_ranges.t @ 593:6c0a5903d0ae

Tests: cleanup now duplicating tests for no alerts.
author Sergey Kandaurov <pluknet@nginx.com>
date Wed, 27 May 2015 17:09:22 +0300
parents 2cd00179f4b2
children e9064d691790
comparison
equal deleted inserted replaced
592:355f2d5ff60f 593:6c0a5903d0ae
21 ############################################################################### 21 ###############################################################################
22 22
23 select STDERR; $| = 1; 23 select STDERR; $| = 1;
24 select STDOUT; $| = 1; 24 select STDOUT; $| = 1;
25 25
26 my $t = Test::Nginx->new()->has(qw/http proxy cache shmem/)->plan(5) 26 my $t = Test::Nginx->new()->has(qw/http proxy cache shmem/)->plan(4)
27 ->write_file_expand('nginx.conf', <<'EOF'); 27 ->write_file_expand('nginx.conf', <<'EOF');
28 28
29 %%TEST_GLOBALS%% 29 %%TEST_GLOBALS%%
30 30
31 daemon off; 31 daemon off;
83 like(http_get_range('/cache/t.html', 'Range: bytes=4-'), qr/^THIS/m, 83 like(http_get_range('/cache/t.html', 'Range: bytes=4-'), qr/^THIS/m,
84 'cached range'); 84 'cached range');
85 like(http_get_range('/cache/t.html', 'Range: bytes=0-2,4-'), qr/^SEE.*^THIS/ms, 85 like(http_get_range('/cache/t.html', 'Range: bytes=0-2,4-'), qr/^SEE.*^THIS/ms,
86 'cached multipart range'); 86 'cached multipart range');
87 87
88 like(`grep -F '[alert]' ${\($t->testdir())}/error.log`, qr/^$/s, 'no alerts');
89
90 ############################################################################### 88 ###############################################################################
91 89
92 sub http_get_range { 90 sub http_get_range {
93 my ($url, $extra) = @_; 91 my ($url, $extra) = @_;
94 return http(<<EOF); 92 return http(<<EOF);