5 use Test::More tests=>4;
8 my $sleep_says = sleep 3;
9 my $diff = time - $start;
11 cmp_ok( $sleep_says, '>=', 2, 'Sleep says it slept at least 2 seconds' );
12 cmp_ok( $sleep_says, '<=', 10, '... and no more than 10' );
14 cmp_ok( $diff, '>=', 2, 'Actual time diff is at least 2 seconds' );
15 cmp_ok( $diff, '<=', 10, '... and no more than 10' );