From: Jarkko Hietaniemi Date: Sun, 25 Nov 2001 21:32:17 +0000 (+0000) Subject: Since in some DOS filesystems the timestamp granularity X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=75bd50b321599253bc5daafb07b3a7ba1bdf8dee;p=p5sagit%2Fp5-mst-13.2.git Since in some DOS filesystems the timestamp granularity may be only two seconds, better sleep for three to play safe. (Helps CygWin, at least.) p4raw-id: //depot/perl@13274 --- diff --git a/lib/Memoize/t/expire_file.t b/lib/Memoize/t/expire_file.t index 022ba18..78a94d4 100644 --- a/lib/Memoize/t/expire_file.t +++ b/lib/Memoize/t/expire_file.t @@ -31,7 +31,7 @@ sub writefile { sub readfile { $READFILE_CALLS++; my $FILE = shift; - open F, "< $FILE" or die "Couldn't write temporary file $FILE: $!"; + open F, "< $FILE" or die "Couldn't read temporary file $FILE: $!"; my $data = ; close F; $data; @@ -61,7 +61,7 @@ my $t2 = readfile($FILE); ++$n; print ((($READFILE_CALLS == 1) ? '' : 'not '), "ok $n\n"); ++$n; print ((($t1 eq $t2) ? '' : 'not '), "ok $n\n"); -sleep 2; +sleep 3; writefile($FILE); my $t3 = readfile($FILE); ++$n; print "ok $n\n";