This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
move the fresh_perl() tests above the environment tests
authorTony Cook <tony@develop-help.com>
Mon, 31 May 2010 23:50:08 +0000 (09:50 +1000)
committerTony Cook <tony@develop-help.com>
Mon, 31 May 2010 23:50:08 +0000 (09:50 +1000)
the environment tests were resetting environment variables useful for
running fresh perls, like LD_LIBRARY_PATH.

t/op/magic.t

index 7e8ab8c..f5f6205 100644 (file)
@@ -279,6 +279,19 @@ is $^O, $orig_osname, 'Assigning $^I does not clobber $^O';
 }
 $^O = $orig_osname;
 
+{
+    #RT #72422
+    foreach my $p (0, 1) {
+       fresh_perl_is(<<"EOP", '2 4 8', undef, "test \$^P = $p");
+\$DB::single = 2;
+\$DB::trace = 4;
+\$DB::signal = 8;
+\$^P = $p;
+print "\$DB::single \$DB::trace \$DB::signal";
+EOP
+    }
+}
+
 SKIP: {
     skip("%ENV manipulations fail or aren't safe on $^O", 4)
        if $Is_VMS || $Is_Dos;
@@ -539,15 +552,3 @@ foreach my $sig (qw(__DIE__ _BOGUS_HOOK KILL THIRSTY)) {
 
 }
 
-{
-    #RT #72422
-    foreach my $p (0, 1) {
-       fresh_perl_is(<<"EOP", '2 4 8', undef, "test \$^P = $p");
-\$DB::single = 2;
-\$DB::trace = 4;
-\$DB::signal = 8;
-\$^P = $p;
-print "\$DB::single \$DB::trace \$DB::signal";
-EOP
-    }
-}