changeset 1021:ebdf239722b9

Tests: relaxed proxy_cache_lock.t nolock tests to fix on Solaris. Assumed that the order of responses being arrived in nolock case may be ignored. An important part of such case is that the only last response should be cached.
author Sergey Kandaurov <pluknet@nginx.com>
date Fri, 02 Sep 2016 12:17:35 +0300
parents 196d33c2bb45
children 616e682e4ca5
files proxy_cache_lock.t
diffstat 1 files changed, 3 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/proxy_cache_lock.t
+++ b/proxy_cache_lock.t
@@ -113,12 +113,10 @@ for my $i (1 .. 3) {
 	$sockets[$i] = http_get('/nolock', start => 1);
 }
 
-like(http_end($sockets[1]), qr/request 1/, 'nolock - first');
+$rest = join '', map { http_end($sockets[$_]) } (1 .. 3);
 
-$rest = http_end($sockets[2]);
-$rest .= http_end($sockets[3]);
-
-like($rest, qr/request (2.*request 3|3.*request 2)/s, 'nolock - rest');
+like($rest, qr/request 1/, 'nolock - first');
+like($rest, qr/request 3/, 'nolock - last');
 like(http_get('/nolock'), qr/request 3/, 'nolock - last cached');
 
 ###############################################################################