From 6ffa69ae0873f45a06f60e385932605e05e60bfa Mon Sep 17 00:00:00 2001 From: "Craig A. Berry" Date: Mon, 18 Feb 2002 05:52:21 -0600 Subject: [PATCH] VMS test fix-ups (alarm.t and glob.t) From: "Craig A. Berry" Message-Id: <5.1.0.14.2.20020218114540.01b2b458@exchi01> p4raw-id: //depot/perl@14749 --- t/op/alarm.t | 5 ++++- t/op/glob.t | 12 +++++++++--- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/t/op/alarm.t b/t/op/alarm.t index 907c385..c008737 100644 --- a/t/op/alarm.t +++ b/t/op/alarm.t @@ -44,4 +44,7 @@ $diff = time - $start_time; # alarm time might be one second less than you said. is( $@, "ALARM!\n", 'alarm w/$SIG{ALRM} vs system()' ); -ok( abs($diff - 3) <= 1, ' right time' ); +{ + local $TODO = 'Why does system() block alarm() on VMS?' if $^O eq 'VMS'; + ok( abs($diff - 3) <= 1, " right time (waited $diff secs for 3-sec alarm)" ); +} diff --git a/t/op/glob.t b/t/op/glob.t index 079919d..89263aa 100755 --- a/t/op/glob.t +++ b/t/op/glob.t @@ -55,9 +55,15 @@ print $i == 2 ? "ok 7\n" : "not ok 7\n"; # ... while ($var = glob(...)) should test definedness not truth -my $ok = "not ok 8\n"; -$ok = "ok 8\n" while my $var = glob("0"); -print $ok; +if( $INC{'File/Glob.pm'} ) { + my $ok = "not ok 8\n"; + $ok = "ok 8\n" while my $var = glob("0"); + print $ok; +} +else { + print "ok 8 # skip: File::Glob emulated Unixism\n"; +} + # The formerly-broken test for the situation above would accidentally # test definedness for an assignment with a LOGOP on the right: -- 2.7.4