summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDavid Mitchell <davem@iabyn.com>2009-07-06 15:39:34 +0100
committerDavid Mitchell <davem@iabyn.com>2009-07-06 15:39:34 +0100
commit45d8b36ec02e88acbbf23bf2514e70f8acb71985 (patch)
tree4c69994b54ab4169d8d293a38d991cdf181ac512 /lib
parent3e887aae38ef79132cc7112942154a36f73033f5 (diff)
downloadperl-45d8b36ec02e88acbbf23bf2514e70f8acb71985.tar.gz
add core boilerplate to three new Test::Simple tests
Diffstat (limited to 'lib')
-rw-r--r--lib/Test/Simple/t/Builder/done_testing_double.t10
-rw-r--r--lib/Test/Simple/t/Builder/done_testing_plan_mismatch.t10
-rw-r--r--lib/Test/Simple/t/Builder/no_plan_at_all.t10
3 files changed, 27 insertions, 3 deletions
diff --git a/lib/Test/Simple/t/Builder/done_testing_double.t b/lib/Test/Simple/t/Builder/done_testing_double.t
index d696384b28..3a0bae247b 100644
--- a/lib/Test/Simple/t/Builder/done_testing_double.t
+++ b/lib/Test/Simple/t/Builder/done_testing_double.t
@@ -1,7 +1,15 @@
#!/usr/bin/perl -w
use strict;
-use lib 't/lib';
+BEGIN {
+ if( $ENV{PERL_CORE} ) {
+ chdir 't';
+ @INC = ('../lib', 'lib');
+ }
+ else {
+ unshift @INC, 't/lib';
+ }
+}
use Test::Builder;
use Test::Builder::NoOutput;
diff --git a/lib/Test/Simple/t/Builder/done_testing_plan_mismatch.t b/lib/Test/Simple/t/Builder/done_testing_plan_mismatch.t
index b815437f80..8208635359 100644
--- a/lib/Test/Simple/t/Builder/done_testing_plan_mismatch.t
+++ b/lib/Test/Simple/t/Builder/done_testing_plan_mismatch.t
@@ -3,7 +3,15 @@
# What if there's a plan and done_testing but they don't match?
use strict;
-use lib 't/lib';
+BEGIN {
+ if( $ENV{PERL_CORE} ) {
+ chdir 't';
+ @INC = ('../lib', 'lib');
+ }
+ else {
+ unshift @INC, 't/lib';
+ }
+}
use Test::Builder;
use Test::Builder::NoOutput;
diff --git a/lib/Test/Simple/t/Builder/no_plan_at_all.t b/lib/Test/Simple/t/Builder/no_plan_at_all.t
index 3909cfe5b7..9029f6f6e7 100644
--- a/lib/Test/Simple/t/Builder/no_plan_at_all.t
+++ b/lib/Test/Simple/t/Builder/no_plan_at_all.t
@@ -3,7 +3,15 @@
# Test what happens when no plan is delcared and done_testing() is not seen
use strict;
-use lib 't/lib';
+BEGIN {
+ if( $ENV{PERL_CORE} ) {
+ chdir 't';
+ @INC = ('../lib', 'lib');
+ }
+ else {
+ unshift @INC, 't/lib';
+ }
+}
use Test::Builder;
use Test::Builder::NoOutput;