Changes for the File::Temp 0.08 (change #6159) test suite
authorJarkko Hietaniemi <jhi@iki.fi>
Mon, 29 May 2000 17:23:55 +0000 (17:23 +0000)
committerJarkko Hietaniemi <jhi@iki.fi>
Mon, 29 May 2000 17:23:55 +0000 (17:23 +0000)
to fit better into the Perl distribution test framework.

p4raw-link: @6159 on //depot/cfgperl: 1c19c86813086fb9efca2171c6506afe1bfe8cc4

p4raw-id: //depot/cfgperl@6160

t/lib/ftmp-mktemp.t
t/lib/ftmp-posix.t
t/lib/ftmp-security.t
t/lib/ftmp-tempfile.t

index 2f41d5d..35ab59c 100755 (executable)
@@ -1,11 +1,16 @@
-#!/usr/local/bin/perl -w
+#!/usr/bin/perl -w
 
 # Test for mktemp family of commands in File::Temp
 # Use STANDARD safe level for these tests
 
+BEGIN {
+       chdir 't' if -d 't';
+       unshift @INC, '../lib';
+       require Test; import Test;
+       plan(tests => 9);
+}
+
 use strict;
-use Test;
-BEGIN { plan tests => 9 }
 
 use File::Spec;
 use File::Path;
index 149ac9a..6802374 100755 (executable)
@@ -1,9 +1,14 @@
-#!/usr/local/bin/perl -w
+#!/usr/bin/perl -w
 # Test for File::Temp - POSIX functions
 
+BEGIN {
+       chdir 't' if -d 't';
+       unshift @INC, '../lib';
+       require Test; import Test;
+       plan(tests => 7);
+}
+
 use strict;
-use Test;
-BEGIN { plan tests => 7}
 
 use File::Temp qw/ :POSIX unlink0 /;
 ok(1);
index a3849bd..06799b3 100755 (executable)
@@ -1,14 +1,18 @@
-#!/usr/local/bin/perl -w
+#!/usr/bin/perl -w
 # Test for File::Temp - Security levels
 
 # Some of the security checking will not work on all platforms
 # Test a simple open in the cwd and tmpdir foreach of the
 # security levels
 
-use strict;
-use Test;
-BEGIN { plan tests => 13}
+BEGIN {
+       chdir 't' if -d 't';
+       unshift @INC, '../lib';
+       require Test; import Test;
+       plan(tests => 13);
+}
 
+use strict;
 use File::Spec;
 
 # Set up END block - this needs to happen before we load
index 517151a..3cb73c2 100755 (executable)
@@ -1,9 +1,14 @@
-#!/usr/local/bin/perl -w
+#!/usr/bin/perl -w
 # Test for File::Temp - tempfile function
 
+BEGIN {
+       chdir 't' if -d 't';
+       unshift @INC, '../lib';
+       require Test; import Test;
+       plan(tests => 11);
+}
+
 use strict;
-use Test;
-BEGIN { plan tests => 11}
 use File::Spec;
 
 # Will need to check that all files were unlinked correctly