Commit | Line | Data |
---|---|---|
4325052d RGS |
1 | #!/usr/bin/perl -w |
2 | ||
41e5fcb0 RGS |
3 | BEGIN { |
4 | if( $ENV{PERL_CORE} ) { | |
5 | chdir 't' if -d 't'; | |
6 | @INC = ('../lib', 'lib'); | |
7 | } | |
8 | else { | |
9 | unshift @INC, 't/lib'; | |
10 | } | |
11 | } | |
12 | chdir 't'; | |
13 | ||
14 | use strict; | |
4325052d | 15 | use Test::More tests => 7; |
41e5fcb0 RGS |
16 | |
17 | use MakeMaker::Test::Setup::BFD; | |
18 | use MakeMaker::Test::Utils; | |
19 | ||
20 | my $perl = which_perl(); | |
21 | my $make = make_run(); | |
22 | perl_lib(); | |
23 | ||
24 | ||
25 | ok( setup_recurs(), 'setup' ); | |
26 | END { | |
27 | ok( chdir File::Spec->updir ); | |
28 | ok( teardown_recurs(), 'teardown' ); | |
29 | } | |
30 | ||
31 | ok( chdir('Big-Dummy'), "chdir'd to Big-Dummy" ) || | |
32 | diag("chdir failed: $!"); | |
33 | ||
34 | my @mpl_out = run(qq{$perl Makefile.PL FIRST_MAKEFILE=jakefile}); | |
35 | cmp_ok( $?, '==', 0, 'Makefile.PL exited with zero' ) || diag @mpl_out; | |
36 | ||
37 | ok( -e 'jakefile', 'FIRST_MAKEFILE honored' ); | |
38 | ||
d04fb41e | 39 | ok( grep(/^Writing jakefile(?:\.)? for Big::Dummy/, @mpl_out) == 1, |
41e5fcb0 | 40 | 'Makefile.PL output looks right' ); |