This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
Win32: set FOO lists values for all variables starting with FOO
authorTony Cook <tony@develop-help.com>
Mon, 22 Jul 2019 23:55:05 +0000 (09:55 +1000)
committerTony Cook <tony@develop-help.com>
Tue, 23 Jul 2019 01:15:56 +0000 (11:15 +1000)
I'd been testing setting FOOBAR to Unicode values, so this test was
failing due to the extra variable.

t/op/magic.t

index 27c1d43..2a7a627 100644 (file)
@@ -104,7 +104,7 @@ END {
 eval '$ENV{"FOO"} = "hi there";';      # check that ENV is inited inside eval
 # cmd.exe will echo 'variable=value' but 4nt will echo just the value
 # -- Nikola Knezevic
-if ($Is_MSWin32)  { like `set FOO`, qr/^(?:FOO=)?hi there$/; }
+if ($Is_MSWin32)  { like `set FOO`, qr/^(?:FOO=)?hi there$/m; }
 elsif ($Is_VMS)   { is `write sys\$output f\$trnlnm("FOO")`, "hi there\n"; }
 else              { is `echo \$FOO`, "hi there\n"; }