NAME ^

t/op/spawnw.t - Run OS commands and tell about the exit code

SYNOPSIS ^

        % prove t/op/spawnw.t

DESCRIPTION ^

Tests spawning external commands.

spawnw does not capture STDOUT and STDERR from the spawned command. So only the exit code can be tested.

The returned value is actually returned from the 'waitpid' system call. In order to get the exit code from the spawned process, it needs to be right shifted by 8 bit.

TODO ^

Test negative return codes.

SEE ALSO ^

The special variable $? in Perl5.

AUTHOR ^

Nigel Sandever - nigelsandever@btconnect.com


parrot