source: vendor/perl/5.8.8/t/comp/script.t

Last change on this file was 3181, checked in by bird, 18 years ago

perl 5.8.8

File size: 621 bytes
Line 
1#!./perl
2
3BEGIN {
4 chdir 't';
5 @INC = '../lib';
6 require './test.pl'; # for which_perl() etc
7}
8
9my $Perl = which_perl();
10
11print "1..3\n";
12
13$x = `$Perl -le "print 'ok';"`;
14
15if ($x eq "ok\n") {print "ok 1\n";} else {print "not ok 1\n";}
16
17open(try,">Comp.script") || (die "Can't open temp file.");
18print try 'print "ok\n";'; print try "\n";
19close try or die "Could not close: $!";
20
21$x = `$Perl Comp.script`;
22
23if ($x eq "ok\n") {print "ok 2\n";} else {print "not ok 2\n";}
24
25$x = `$Perl <Comp.script`;
26
27if ($x eq "ok\n") {print "ok 3\n";} else {print "not ok 3\n";}
28
29unlink 'Comp.script' || `/bin/rm -f Comp.script`;
Note: See TracBrowser for help on using the repository browser.