# HG changeset patch # User Sergey Kandaurov # Date 1429617170 -10800 # Node ID 28a8248740ca5d0eabaa13962b41ba5f6a079bfa # Parent a04b8b9537cd91ecef38d44d7a644537341c2abf Tests: proxy cache lock tests adjusted. Sometimes, events for expired proxy_cache_lock_timeout may be processed out of order, notably with Solaris devpoll, which leads to spurious test failures. Tests are modified to sustain such disorder. diff --git a/proxy_cache_lock.t b/proxy_cache_lock.t --- a/proxy_cache_lock.t +++ b/proxy_cache_lock.t @@ -69,7 +69,7 @@ EOF $t->run_daemon(\&http_fake_daemon); -$t->run()->plan(19); +$t->run()->plan(18); $t->waitforsocket('127.0.0.1:8081'); @@ -101,9 +101,12 @@ for my $i (1 .. 3) { $sockets[$i] = http_get('/timeout', start => 1); } -for my $i (1 .. 3) { - like(http_end($sockets[$i]), qr/request $i/, 'lock timeout ' . $i); -} +like(http_end($sockets[1]), qr/request 1/, 'lock timeout - first'); + +my $rest = http_end($sockets[2]); +$rest .= http_end($sockets[3]); + +like($rest, qr/request (2.*request 3|3.*request 2)/s, 'lock timeout - rest'); TODO: { local $TODO = 'behavior change' unless $t->has_version('1.7.8');