diff proxy_store.t @ 233:1a5574d84917

Tests: tweak various timeouts and replace sleep() with select(). Hopefully this will result in less spurious test failures, in particular on our Solaris VM.
author Maxim Dounin <mdounin@mdounin.ru>
date Mon, 10 Sep 2012 20:18:05 +0400
parents ba992cfdc606
children 5ac875a3088e
line wrap: on
line diff
--- a/proxy_store.t
+++ b/proxy_store.t
@@ -83,13 +83,13 @@ ok(!-e $t->testdir() . '/store-index-nos
 ok(scalar @{[ glob $t->testdir() . '/proxy_temp/*' ]} == 0, 'no temp files');
 
 http_get('/store-index-big.html', aborted => 1, sleep => 0.1);
-sleep(1);
+select(undef, undef, undef, 0.5);
 
 ok(scalar @{[ glob $t->testdir() . '/proxy_temp/*' ]} == 0,
 	'no temp files after aborted request');
 
 http_get('/ssi.html', aborted => 1, sleep => 0.1);
-sleep(1);
+select(undef, undef, undef, 0.5);
 
 ok(scalar @{[ glob $t->testdir() . '/proxy_temp/*' ]} == 0,
 	'no temp files after aborted ssi');