X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=blobdiff_plain;f=t%2Fop%2Fanonsub.t;h=893a72671cff16e720db672f184bb43593f2585c;hb=de11ba31bba9f0eef0f76239d1d93a010926d6cf;hp=aa25de0131b1f84a36ff2741054bf3c907ea6a9b;hpb=95e8664e86da93255f26600f44bbbd70bf5b5b0e;p=p5sagit%2Fp5-mst-13.2.git diff --git a/t/op/anonsub.t b/t/op/anonsub.t index aa25de0..893a726 100755 --- a/t/op/anonsub.t +++ b/t/op/anonsub.t @@ -5,6 +5,7 @@ chdir 't' if -d 't'; $Is_VMS = $^O eq 'VMS'; $Is_MSWin32 = $^O eq 'MSWin32'; $Is_MacOS = $^O eq 'MacOS'; +$Is_NetWare = $^O eq 'NetWare'; $ENV{PERL5LIB} = "../lib" unless $Is_VMS; $|=1; @@ -25,14 +26,16 @@ for (@prgs){ my($prog,$expected) = split(/\nEXPECT\n/, $_); open TEST, ">$tmpfile"; print TEST "$prog\n"; - close TEST; + close TEST or die "Could not close: $!"; my $results = $Is_VMS ? `MCR $^X "-I[-.lib]" $switch $tmpfile 2>&1` : $Is_MSWin32 ? `.\\perl -I../lib $switch $tmpfile 2>&1` : $Is_MacOS ? `$^X -I::lib $switch $tmpfile` : - `./perl $switch $tmpfile 2>&1`; + $Is_NetWare ? + `perl -I../lib $switch $tmpfile 2>&1` : + `./perl $switch $tmpfile 2>&1`; my $status = $?; $results =~ s/\n+$//; # allow expected output to be written as if $prog is on STDIN @@ -94,3 +97,7 @@ sub X { X(); EXPECT ok 1 +######## +print sub { return "ok 1\n" } -> (); +EXPECT +ok 1