diff options
author | Jarkko Hietaniemi <jhi@iki.fi> | 2001-06-27 19:55:16 +0000 |
---|---|---|
committer | Jarkko Hietaniemi <jhi@iki.fi> | 2001-06-27 19:55:16 +0000 |
commit | 12b8e1e4619e2f84702749a446aad4e8d554b7ed (patch) | |
tree | 4c6287dd176f2d107a47b70bcf4635b69d7750ca | |
parent | 11ea77c506634ef402471f4a078b60f79302be3f (diff) | |
download | perl-12b8e1e4619e2f84702749a446aad4e8d554b7ed.tar.gz |
The Test::More and Test::Simple tests required help
thanks to our schizophrenic test scheme.
p4raw-id: //depot/perl@10994
-rw-r--r-- | lib/Test/More/t/fail-like.t | 2 | ||||
-rw-r--r-- | lib/Test/More/t/fail.t | 2 | ||||
-rw-r--r-- | lib/Test/More/t/plan_is_noplan.t | 2 | ||||
-rw-r--r-- | lib/Test/More/t/skipall.t | 2 | ||||
-rw-r--r-- | lib/Test/Simple/t/exit.t | 7 | ||||
-rw-r--r-- | lib/Test/Simple/t/extra.t | 2 | ||||
-rw-r--r-- | lib/Test/Simple/t/fail.t | 2 | ||||
-rw-r--r-- | lib/Test/Simple/t/missing.t | 2 | ||||
-rw-r--r-- | lib/Test/Simple/t/no_plan.t | 2 | ||||
-rw-r--r-- | lib/Test/Simple/t/plan_is_noplan.t | 2 |
10 files changed, 15 insertions, 10 deletions
diff --git a/lib/Test/More/t/fail-like.t b/lib/Test/More/t/fail-like.t index 9bac0afb19..98564fd05a 100644 --- a/lib/Test/More/t/fail-like.t +++ b/lib/Test/More/t/fail-like.t @@ -35,7 +35,7 @@ sub ok ($;$) { package main; require Test::More; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/More'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/More/t/fail.t b/lib/Test/More/t/fail.t index d684e65f1b..9645e2b687 100644 --- a/lib/Test/More/t/fail.t +++ b/lib/Test/More/t/fail.t @@ -22,7 +22,7 @@ sub ok ($;$) { package main; require Test::More; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/More'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/More/t/plan_is_noplan.t b/lib/Test/More/t/plan_is_noplan.t index 29ccd6b649..b0c031ee3e 100644 --- a/lib/Test/More/t/plan_is_noplan.t +++ b/lib/Test/More/t/plan_is_noplan.t @@ -21,7 +21,7 @@ package main; require Test::More; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/More'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/More/t/skipall.t b/lib/Test/More/t/skipall.t index bfee83dbb3..ff7607dd43 100644 --- a/lib/Test/More/t/skipall.t +++ b/lib/Test/More/t/skipall.t @@ -22,7 +22,7 @@ sub ok ($;$) { package main; require Test::More; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/More'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/Simple/t/exit.t b/lib/Test/Simple/t/exit.t index 7247a0c763..dac5c48a1a 100644 --- a/lib/Test/Simple/t/exit.t +++ b/lib/Test/Simple/t/exit.t @@ -33,8 +33,13 @@ my %Tests = ( print "1..".keys(%Tests)."\n"; chdir 't' if -d 't'; +use File::Spec; +my $lib = File::Spec->catdir('lib', 'Test', 'Simple', 'sample_tests'); while( my($test_name, $exit_code) = each %Tests ) { - my $wait_stat = system(qq{$^X -"I../blib/lib" sample_tests/$test_name}); + my $file = File::Spec->catfile($lib, $test_name); + my $wait_stat = system(qq{$^X -"I../lib" -"Ilib/Test/Simple" $file}); My::Test::ok( $wait_stat >> 8 == $exit_code, "$test_name exited with $exit_code" ); } + + diff --git a/lib/Test/Simple/t/extra.t b/lib/Test/Simple/t/extra.t index ba04517f15..d2161e3d2c 100644 --- a/lib/Test/Simple/t/extra.t +++ b/lib/Test/Simple/t/extra.t @@ -21,7 +21,7 @@ package main; require Test::Simple; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/Simple'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/Simple/t/fail.t b/lib/Test/Simple/t/fail.t index c0bd42ec2e..a29158840a 100644 --- a/lib/Test/Simple/t/fail.t +++ b/lib/Test/Simple/t/fail.t @@ -23,7 +23,7 @@ package main; require Test::Simple; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/Simple'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/Simple/t/missing.t b/lib/Test/Simple/t/missing.t index 867639b057..711dbb41cc 100644 --- a/lib/Test/Simple/t/missing.t +++ b/lib/Test/Simple/t/missing.t @@ -21,7 +21,7 @@ package main; require Test::Simple; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/Simple'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/Simple/t/no_plan.t b/lib/Test/Simple/t/no_plan.t index 9e4290b5fd..327f3cab89 100644 --- a/lib/Test/Simple/t/no_plan.t +++ b/lib/Test/Simple/t/no_plan.t @@ -21,7 +21,7 @@ package main; require Test::Simple; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/Simple'); require Catch; my($out, $err) = Catch::caught(); diff --git a/lib/Test/Simple/t/plan_is_noplan.t b/lib/Test/Simple/t/plan_is_noplan.t index 8cf11c5ee3..0e496055c6 100644 --- a/lib/Test/Simple/t/plan_is_noplan.t +++ b/lib/Test/Simple/t/plan_is_noplan.t @@ -30,7 +30,7 @@ package main; require Test::Simple; -push @INC, 't', '.'; +@INC = ('../lib', 'lib/Test/Simple'); require Catch; my($out, $err) = Catch::caught(); |