summaryrefslogtreecommitdiff
path: root/ext/B/t/optree_concise.t
diff options
context:
space:
mode:
Diffstat (limited to 'ext/B/t/optree_concise.t')
-rw-r--r--ext/B/t/optree_concise.t11
1 files changed, 8 insertions, 3 deletions
diff --git a/ext/B/t/optree_concise.t b/ext/B/t/optree_concise.t
index d4d6d32967..00a04cb79f 100644
--- a/ext/B/t/optree_concise.t
+++ b/ext/B/t/optree_concise.t
@@ -1,8 +1,13 @@
#!perl
BEGIN {
- chdir 't';
- @INC = ('../lib', '../ext/B/t');
+ if ($ENV{PERL_CORE}){
+ chdir('t') if -d 't';
+ @INC = ('.', '../lib', '../ext/B/t');
+ } else {
+ unshift @INC, 't';
+ push @INC, "../../t";
+ }
require Config;
if (($Config::Config{'extensions'} !~ /\bB\b/) ){
print "1..0 # Skip -- Perl configured without B module\n";
@@ -13,7 +18,7 @@ BEGIN {
"1..0 # Skip: Data::Dumper was not built, needed by OptreeCheck\n";
exit 0;
}
- require './test.pl';
+ require 'test.pl';
}
# import checkOptree(), and %gOpts (containing test state)