ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/cvsroot/Proc-FastSpawn/t/01_basic.t
Revision: 1.2
Committed: Sun Apr 28 00:49:43 2013 UTC (13 years, 4 months ago) by root
Content type: application/x-troff
Branch: MAIN
CVS Tags: rel-1_1, rel-1_2, HEAD
Changes since 1.1: +10 -1 lines
Error occurred while calculating annotation data.
Log Message:
1.1

File Contents

# Content
1 BEGIN { $| = 1; print "1..9\n"; }
2
3 use Proc::FastSpawn;
4
5 print "ok 1\n";
6
7 my $pid = spawn $^X, ["perl", "-e", "exit 5"];
8 print $pid ? "" : "not ", "ok 2\n";
9 print +($pid == waitpid $pid, 0) ? "" : "not ", "ok 3\n";
10 print $? == 0x0500 ? "" : "not ", "ok 4\n";
11
12 print "ok 5\n";
13
14 $pid = spawnp $^X, ["perl", "-e", "exit 6"];
15 print $pid ? "" : "not ", "ok 6\n";
16 print +($pid == waitpid $pid, 0) ? "" : "not ", "ok 7\n";
17 print $? == 0x0600 ? "" : "not ", "ok 8\n";
18
19 print "ok 9\n";