VMS fixups for IO::* tests
authorMichael G. Schwern <schwern@pobox.com>
Tue, 13 Nov 2001 20:27:02 +0000 (15:27 -0500)
committerAbhijit Menon-Sen <ams@wiw.org>
Wed, 14 Nov 2001 00:32:15 +0000 (00:32 +0000)
Message-Id: <20011113202702.D32567@blackrider>

p4raw-id: //depot/perl@12984

ext/IO/lib/IO/t/io_const.t
ext/IO/lib/IO/t/io_dir.t
ext/IO/lib/IO/t/io_dup.t
ext/IO/lib/IO/t/io_pipe.t
ext/IO/lib/IO/t/io_sock.t
ext/IO/lib/IO/t/io_unix.t
ext/IO/lib/IO/t/io_xs.t
vms/test.com

index db1a322..13bb65c 100755 (executable)
@@ -9,10 +9,10 @@ BEGIN {
 use Config;
 
 BEGIN {
-    if(-d "lib" && -f "TEST") {
-        if ($Config{'extensions'} !~ /\bIO\b/ && $^O ne 'VMS') {
-           print "1..0\n";
-           exit 0;
+    if($ENV{PERL_CORE}) {
+        if ($Config{'extensions'} !~ /\bIO\b/) {
+            print "1..0 # Skip: IO extension not compiled\n";
+            exit 0;
         }
     }
 }
index 6ec4e9f..a6f03d0 100755 (executable)
@@ -7,7 +7,7 @@ BEGIN {
     }
     require Config; import Config;
     if ($] < 5.00326 || not $Config{'d_readdir'}) {
-       print "1..0\n";
+       print "1..0 # Skip: readdir() not available\n";
        exit 0;
     }
 }
index 5db5ced..351a38d 100755 (executable)
@@ -10,9 +10,9 @@ BEGIN {
 use Config;
 
 BEGIN {
-    if(-d "lib" && -f "TEST") {
-        if ($Config{'extensions'} !~ /\bIO\b/ && $^O ne 'VMS') {
-           print "1..0\n";
+    if($ENV{PERL_CORE}) {
+        if ($Config{'extensions'} !~ /\bIO\b/) {
+           print "1..0 # Skip: IO extension not compiled\n";
            exit 0;
         }
     }
index ae18224..a8bc483 100755 (executable)
@@ -18,7 +18,6 @@ BEGIN {
        elsif ($Config{'extensions'} !~ /\bIO\b/) {
            $reason = 'IO extension unavailable';
        }
-       undef $reason if $^O eq 'VMS';
        if ($reason) {
            print "1..0 # Skip: $reason\n";
            exit 0;
index 6b241c5..c4bfcc4 100755 (executable)
@@ -21,7 +21,6 @@ BEGIN {
        elsif ($Config{'extensions'} !~ /\bIO\b/) {
            $reason = 'IO extension unavailable';
        }
-       undef $reason if $^O eq 'VMS' and $Config{d_socket};
        if ($reason) {
            print "1..0 # Skip: $reason\n";
            exit 0;
index f120c97..e8ce473 100644 (file)
@@ -30,7 +30,6 @@ BEGIN {
        } elsif ($^O =~ m/^(?:qnx|nto)$/ ) {
            $reason = 'Not implemented';
        }
-       undef $reason if $^O eq 'VMS' and $Config{d_socket};
        if ($reason) {
            print "1..0 # Skip: $reason\n";
            exit 0;
index 2449fc4..2ef9577 100644 (file)
@@ -10,12 +10,16 @@ BEGIN {
 use Config;
 
 BEGIN {
-    if(-d "lib" && -f "TEST") {
-        if ($Config{'extensions'} !~ /\bIO\b/ && $^O ne 'VMS') {
-           print "1..0\n";
+    if($ENV{PERL_CORE}) {
+        if ($Config{'extensions'} !~ /\bIO\b/) {
+           print "1..0 # Skip: IO extension not built\n";
            exit 0;
         }
     }
+    if( $^O eq 'VMS' && $Config{'vms_cc_type'} ne 'decc' ) {
+        print "1..0 # Skip: not compatible with the VAXCRTL\n";
+        exit 0;
+    }
 }
 
 use IO::File;
index 62532f5..ac63c22 100644 (file)
@@ -115,13 +115,7 @@ use Config;
 use File::Spec;
 
 @compexcl=('cpp.t');
-@libexcl=('io_pipe.t', 'io_poll.t', 'io_sel.t',
-          'io_sock.t', 'io_unix.t');
-
-# io_xs.t tests the new_tmpfile routine, which doesn't work with the
-# VAXCRTL, since the file can't be stat()d, an Perl's do_open()
-# insists on stat()ing a file descriptor before it'll use it.
-push(@libexcl,'io_xs.t') if $Config{'vms_cc_type'} ne 'decc';
+@libexcl=('io_sel.t');
 
 @opexcl=('die_exit.t','exec.t','groups.t','magic.t','stat.t');
 @exclist=(@compexcl,@ioexcl,@libexcl,@opexcl);