t/pt-query-digest/read_timeout.t: Make the tests slightly more forgiving for slow computers

This commit is contained in:
Brian Fraser fraserb@gmail.com
2012-06-05 11:04:10 -03:00
parent a00542aec8
commit 422308ffc5

View File

@@ -13,6 +13,8 @@ use Test::More tests => 2;
use PerconaTest; use PerconaTest;
use Time::HiRes qw(sleep time);
# ######################################################################### # #########################################################################
# Issue 226: Fix mk-query-digest signal handling # Issue 226: Fix mk-query-digest signal handling
# ######################################################################### # #########################################################################
@@ -36,8 +38,8 @@ if ( $timeout ) {
} }
ok( ok(
$waited >= 2 && $waited <= 3, $waited >= 2 && $waited < 4,
"--read-timeout 2 waited $waited seconds reading STDIN" sprintf("--read-timeout 2 waited %.1f seconds reading STDIN", $waited)
); );
diag(`rm -rf /tmp/mqd.pid`); diag(`rm -rf /tmp/mqd.pid`);
@@ -61,8 +63,8 @@ if ( $timeout ) {
} }
ok( ok(
$waited >= 2 && $waited <= 3, $waited >= 2 && $waited < 4,
"--read-timeout waited $waited seconds reading a file" sprintf("--read-timeout waited %.1f seconds reading a file", $waited)
); );
diag(`rm -rf /tmp/mqd.pid`); diag(`rm -rf /tmp/mqd.pid`);