Commit | Line | Data |
39234879 |
1 | #!/usr/bin/perl -w |
7a5004db |
2 | |
3 | BEGIN { |
39234879 |
4 | if( $ENV{PERL_CORE} ) { |
5 | chdir 't' if -d 't'; |
6 | @INC = '../lib'; |
7 | } |
f6d6199c |
8 | else { |
9 | unshift @INC, 't/lib'; |
10 | } |
7a5004db |
11 | } |
39234879 |
12 | chdir 't'; |
7a5004db |
13 | |
14 | use Test::More tests => 3; |
15 | |
39234879 |
16 | BEGIN { |
17 | # non-core tests will have blib in their path. We remove it |
18 | # and just use the one in lib/. |
19 | unless( $ENV{PERL_CORE} ) { |
20 | @INC = grep !/blib/, @INC; |
21 | unshift @INC, '../lib'; |
22 | } |
23 | } |
24 | |
25 | my @blib_paths = grep /blib/, @INC; |
7a5004db |
26 | is( @blib_paths, 0, 'No blib dirs yet in @INC' ); |
27 | |
28 | use_ok( 'ExtUtils::testlib' ); |
29 | |
30 | @blib_paths = grep { /blib/ } @INC; |
31 | is( @blib_paths, 2, 'ExtUtils::testlib added two @INC dirs!' ); |