# HG changeset patch # User Sergey Kandaurov # Date 1429272727 -10800 # Node ID 714668aea2b0dce4c3d43b37bc22eb9bf984a3f0 # Parent fa48f8a195a305c0c701bf230f42532d016c7345 Tests: adjusted proxy_cache_lock tests with subrequests. Start time is now taken from nginx for greater accuracy. diff --git a/proxy_cache_lock_ssi.t b/proxy_cache_lock_ssi.t --- a/proxy_cache_lock_ssi.t +++ b/proxy_cache_lock_ssi.t @@ -53,6 +53,8 @@ http { proxy_cache_lock_timeout 100ms; proxy_read_timeout 2s; + + add_header X-Msec $msec; } location = /ssi.html { @@ -94,11 +96,9 @@ EOF # is woken up by the postpone filter once first subrequest completes, # but this is suboptimal behaviour -my $start = time(); - my $s = http_get('/locked', start => 1); like(http_get('/ssi.html'), qr/end/, 'cache lock ssi'); -http_end($s); +my ($start) = http_end($s) =~ /X-Msec: (\d+)/; TODO: { local $TODO = 'not yet' unless $t->has_version('1.7.8');