Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

[t/spec]: Rewrite sleep.t to avoid use of cmp_ok() function.

git-svn-id: http://svn.pugscode.org/pugs@24530 c213334d-75ef-0310-aa23-eaa082d1ae64
  • Loading branch information...
commit cb3f3d791993b4776ec883b47562c184b413868e 1 parent 137da2e
pmichaud authored
Showing with 4 additions and 4 deletions.
  1. +4 −4 S29-context/sleep.t
View
8 S29-context/sleep.t
@@ -11,8 +11,8 @@ diag "Sleeping for 3s";
my $sleep_says = sleep 3;
my $diff = time() - $start;
-cmp_ok( $sleep_says, &infix:«>=», 2, 'Sleep says it slept at least 2 seconds');
-cmp_ok( $sleep_says, &infix:«<=», 10, '... and no more than 10' );
+ok( $sleep_says >= 2 , 'Sleep says it slept at least 2 seconds');
+ok( $sleep_says <= 10 , '... and no more than 10');
-cmp_ok( $diff, &infix:«>=», 2, 'Actual time diff is at least 2 seconds' );
-cmp_ok( $diff, &infix:«<=», 10, '... and no more than 10' );
+ok( $diff >= 2 , 'Sleep says it slept at least 2 seconds');
+ok( $diff <= 10 , '... and no more than 10');

0 comments on commit cb3f3d7

Please sign in to comment.
Something went wrong with that request. Please try again.