In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/77f118c279be3f2b4aaa364f584602f96d70b97c?hp=4f2e2aa236a3300a5f46fd5b3f02db9cf158f62f>

- Log -----------------------------------------------------------------
commit 77f118c279be3f2b4aaa364f584602f96d70b97c
Merge: 4f2e2aa 60acf81
Author: H.Merijn Brand <[email protected]>
Date:   Thu Jun 6 16:18:44 2013 +0200

    Merge remote-tracking branch 'remotes/origin/smoke-me/env-instead-of-echo' 
into blead
-----------------------------------------------------------------------

Summary of changes:
 t/op/magic.t |   17 +++++++++--------
 1 files changed, 9 insertions(+), 8 deletions(-)

diff --git a/t/op/magic.t b/t/op/magic.t
index b7ce3ae..ac66b60 100644
--- a/t/op/magic.t
+++ b/t/op/magic.t
@@ -56,11 +56,11 @@ $Is_Dos      = $^O eq 'dos';
 $Is_os2      = $^O eq 'os2';
 $Is_Cygwin   = $^O eq 'cygwin';
 
-$PERL = $ENV{PERL}
-    || ($Is_NetWare           ? 'perl'   :
-       $Is_VMS                ? $^X      :
-       $Is_MSWin32            ? '.\perl' :
-       './perl');
+$PERL = $ENV{PERL} ||
+   ($Is_NetWare ? 'perl'   :
+    $Is_VMS     ? $^X      :
+    $Is_MSWin32 ? '.\perl' :
+                  './perl');
 
 sub env_is {
     my ($key, $val, $desc) = @_;
@@ -82,7 +82,8 @@ sub env_is {
         $eqv = "\n" if length($eqv) == 2 and $eqv eq "\000\n";
         is $eqv, "$val\n", $desc;
     } else {
-        is `echo \$\Q$key\E`, "$val\n", $desc;
+        chomp (my @env = grep { s/^$key=// } `env`);
+        is "@env", $val, $desc;
     }
 }
 
@@ -625,10 +626,10 @@ is ${^LAST_FH}, undef, '${^LAST_FH} is undef when 
PL_last_in_gv is NULL';
 
 
 # $|
-fresh_perl_is 'print $| = ~$|', "1\n", {switches => ['-l']}, 
+fresh_perl_is 'print $| = ~$|', "1\n", {switches => ['-l']},
  '[perl #4760] print $| = ~$|';
 fresh_perl_is
- 'select f; undef *f; ${q/|/}; print STDOUT qq|ok\n|', "ok\n", {}, 
+ 'select f; undef *f; ${q/|/}; print STDOUT qq|ok\n|', "ok\n", {},
  '[perl #115206] no crash when vivifying $| while *{+select}{IO} is undef';
 
 

--
Perl5 Master Repository

Reply via email to