This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Get pat_re_eval.t working under minitest
authorFather Chrysostomos <sprout@cpan.org>
Mon, 1 Sep 2014 05:34:41 +0000 (22:34 -0700)
committerFather Chrysostomos <sprout@cpan.org>
Wed, 3 Sep 2014 03:11:14 +0000 (20:11 -0700)
minitest can run before everything is built.  Hence, we need to make sure
the directories that buildcustomize.pl puts in @INC are not clobbered by
the test script.

t/re/pat_re_eval.t

index 309d0e9..b041828 100644 (file)
@@ -17,8 +17,9 @@ $| = 1;
 
 BEGIN {
     chdir 't' if -d 't';
 
 BEGIN {
     chdir 't' if -d 't';
-    @INC = ('../lib','.');
     require './test.pl';
     require './test.pl';
+    @INC = () unless is_miniperl();
+    unshift @INC, '../lib';
 }
 
 
 }