diff options
author | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-11-03 10:12:06 +0000 |
---|---|---|
committer | Rafael Garcia-Suarez <rgarciasuarez@gmail.com> | 2007-11-03 10:12:06 +0000 |
commit | 680ed74dc0c52ab677066ffb3d985dceec0d8bfd (patch) | |
tree | 0af956f48898b4c36d00b047ea62fa7ba2267371 | |
parent | 33de8e4aff58f134481d1a594f7a9734709d8ea5 (diff) | |
download | perl-680ed74dc0c52ab677066ffb3d985dceec0d8bfd.tar.gz |
Based on a patch by John E. Malberg: make TestInit.pm
use an absolute path in @INC, so that changes of directories
don't break dynamically loaded modules.
p4raw-id: //depot/perl@32214
-rw-r--r-- | t/TestInit.pm | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/t/TestInit.pm b/t/TestInit.pm index aa76fe194b..058ad29292 100644 --- a/t/TestInit.pm +++ b/t/TestInit.pm @@ -18,7 +18,13 @@ package TestInit; $VERSION = 1.01; chdir 't' if -d 't'; -@INC = '../lib'; +if ($^O eq 'VMS') { + require File::Spec; + @INC = File::Spec->rel2abs('[-.lib]'); +} +else { + @INC = '../lib'; +} # Don't interfere with the taintedness of %ENV, this could perturbate tests $ENV{PERL_CORE} = 1 unless ${^TAINT}; |