This is a live mirror of the Perl 5 development currently hosted at https://github.com/perl/perl5
In t/op/eval.t, move logic from a spawned program into the main test script.
This also allows a chunk of it to be removed. There's no need inside a spawned
script to
a: dup STDERR so that it can be restored
b: open STDERR to a temporary file
c: call Devel::Peek::Dump
d: close the temporary file
e: restore STDERR
f: open it for reading
g: manipulate the contents
h: return ok/not ot
when instead we can run step 'c' only, with STDERR captured, perform step 'g'
only in the main script, and finish with an is() test instead of an ok()
This also saves having to substitute a generated temporary filename into the
code for the spawned script.
[Collateral "damage" is converting the next test to use test.pl's is()]