In t/harness, clear PERL5LIB, PERLLIB, PERL5OPT as t/TEST does.
authorNicholas Clark <nick@ccl4.org>
Fri, 9 Jul 2010 09:42:41 +0000 (10:42 +0100)
committerNicholas Clark <nick@ccl4.org>
Fri, 9 Jul 2010 09:43:47 +0000 (10:43 +0100)
In fact, as t/harness requires t/TEST, simply get t/TEST to do it for
t/harness too.

t/TEST

diff --git a/t/TEST b/t/TEST
index d4bf64c..92c9bf5 100755 (executable)
--- a/t/TEST
+++ b/t/TEST
@@ -86,19 +86,6 @@ my %temp_no_core =
      '../cpan/Unicode-Normalize' => 1,
     );
 
-if ($::do_nothing) {
-    return 1;
-}
-
-# Location to put the Valgrind log.
-our $Valgrind_Log;
-
-$| = 1;
-
-# for testing TEST only
-#BEGIN { require '../lib/strict.pm'; "strict"->import() };
-#BEGIN { require '../lib/warnings.pm'; "warnings"->import() };
-
 # delete env vars that may influence the results
 # but allow override via *_TEST env var if wanted
 # (e.g. PERL5OPT_TEST=-d:NYTProf)
@@ -113,6 +100,19 @@ for my $envname (qw(PERL5LIB PERLLIB PERL5OPT)) {
     }
 }
 
+if ($::do_nothing) {
+    return 1;
+}
+
+# Location to put the Valgrind log.
+our $Valgrind_Log;
+
+$| = 1;
+
+# for testing TEST only
+#BEGIN { require '../lib/strict.pm'; "strict"->import() };
+#BEGIN { require '../lib/warnings.pm'; "warnings"->import() };
+
 # remove empty elements due to insertion of empty symbols via "''p1'" syntax
 @ARGV = grep($_,@ARGV) if $^O eq 'VMS';
 our $show_elapsed_time = $ENV{HARNESS_TIMER} || 0;