home *** CD-ROM | disk | FTP | other *** search
/ Power-Programmierung / CD1.mdf / perl / os2perl / script.t < prev    next >
Text File  |  1991-06-16  |  528b  |  24 lines

  1. #!./perl
  2.  
  3. # $Header: script.t,v 4.0 91/03/20 01:50:26 lwall Locked $
  4.  
  5. print "1..3\n";
  6.  
  7. $x = `perl -e "print \\\"ok\\n\\\";"`;
  8.  
  9. if ($x eq "ok\n") {print "ok 1\n";} else {print "not ok 1\n";}
  10.  
  11. open(try,">Comp.script") || (die "Can't open temp file.");
  12. print try 'print "ok\n";'; print try "\n";
  13. close try;
  14.  
  15. $x = `perl Comp.script`;
  16.  
  17. if ($x eq "ok\n") {print "ok 2\n";} else {print "not ok 2\n";}
  18.  
  19. $x = `perl <Comp.script`;
  20.  
  21. if ($x eq "ok\n") {print "ok 3\n";} else {print "not ok 3\n";}
  22.  
  23. `del Comp.script`;
  24.