summaryrefslogtreecommitdiff
path: root/t/test.pl
diff options
context:
space:
mode:
authorJarkko Hietaniemi <jhi@iki.fi>2002-04-28 20:26:30 +0000
committerJarkko Hietaniemi <jhi@iki.fi>2002-04-28 20:26:30 +0000
commitdc459aad73ffc3aaf43c03d9908415c433fd93ba (patch)
tree981bdcf9828bbd255b79fd1181324eb2b45d8a61 /t/test.pl
parent21f5a6076e634a7ee61d6f5aa4e44bf6708db9fb (diff)
downloadperl-dc459aad73ffc3aaf43c03d9908415c433fd93ba.tar.gz
Integrate #16254 from macperl;
Fix most tests on MacOS (not yet ext/ or /lib) p4raw-id: //depot/perl@16257
Diffstat (limited to 't/test.pl')
-rw-r--r--t/test.pl21
1 files changed, 17 insertions, 4 deletions
diff --git a/t/test.pl b/t/test.pl
index a58b86cf51..7df12b6f4d 100644
--- a/t/test.pl
+++ b/t/test.pl
@@ -378,15 +378,28 @@ sub runperl {
$runperl .= qq( "$args{progfile}");
}
if (defined $args{stdin}) {
- # so we don't try to put literal newlines and crs onto the
- # command line.
- $args{stdin} =~ s/\n/\\n/g;
- $args{stdin} =~ s/\r/\\r/g;
+ # so we don't try to put literal newlines and crs onto the
+ # command line.
+ $args{stdin} =~ s/\n/\\n/g;
+ $args{stdin} =~ s/\r/\\r/g;
if ($is_mswin || $is_netware || $is_vms) {
$runperl = qq{$^X -e "print qq(} .
$args{stdin} . q{)" | } . $runperl;
}
+ elsif ($is_macos) {
+ # MacOS can only do two processes under MPW at once;
+ # the test itself is one; we can't do two more, so
+ # write to temp file
+ my $stdin = qq{$^X -e 'print qq(} . $args{stdin} . qq{)' > teststdin; };
+ if ($args{verbose}) {
+ my $stdindisplay = $stdin;
+ $stdindisplay =~ s/\n/\n\#/g;
+ print STDERR "# $stdindisplay\n";
+ }
+ `$stdin`;
+ $runperl .= q{ < teststdin };
+ }
else {
$runperl = qq{$^X -e 'print qq(} .
$args{stdin} . q{)' | } . $runperl;