diff options
author | Nicholas Clark <nick@ccl4.org> | 2011-03-06 17:50:36 +0000 |
---|---|---|
committer | Nicholas Clark <nick@ccl4.org> | 2011-03-06 20:39:56 +0000 |
commit | 79c67e3326f78c5970f69cc0b31a35619eb41e9a (patch) | |
tree | 24c3ea6ca3292359f6f02e3606693aaf53f00ce7 /t/op/chdir.t | |
parent | 8594e3bf75762cb96215c73368f7f03d2f42485c (diff) | |
download | perl-79c67e3326f78c5970f69cc0b31a35619eb41e9a.tar.gz |
Ensure that chdir.t can find File::Spec and Cwd under minitest
As a working chdir is a key part of the build process, it would be counter-
productive to skip testing it if the build process failed, because it might be
cause of the problems. So add the source locations for Cwd and File::Spec in
dist/Cwd and dist/Cwd/lib respectively.
Diffstat (limited to 't/op/chdir.t')
-rw-r--r-- | t/op/chdir.t | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/t/op/chdir.t b/t/op/chdir.t index a0c60bfb8a..2c6535bde9 100644 --- a/t/op/chdir.t +++ b/t/op/chdir.t @@ -5,11 +5,16 @@ BEGIN { # chdir() works! Instead, we'll hedge our bets and put both # possibilities into @INC. @INC = qw(t . lib ../lib); + require "test.pl"; + # Really want to know if chdir is working, as the build process will all go + # wrong if it is not. + if (is_miniperl() && !eval {require File::Spec::Functions; 1}) { + push @INC, qw(dist/Cwd/lib dist/Cwd ../dist/Cwd/lib ../dist/Cwd); + } + plan(tests => 48); } use Config; -require "test.pl"; -plan(tests => 48); my $IsVMS = $^O eq 'VMS'; |