From: Perl 5 Porters Date: Thu, 18 Jul 1996 01:17:40 +0000 (+0000) Subject: perl 5.003_01: t/lib/filehand.t X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=5ef887f565b93732e1d57415b9f72359f638b378;p=p5sagit%2Fp5-mst-13.2.git perl 5.003_01: t/lib/filehand.t Can't call FileHandle methods on unblessed file handle, since IO::Handle is now the default class --- diff --git a/t/lib/filehand.t b/t/lib/filehand.t index fc43350..0199a52 100755 --- a/t/lib/filehand.t +++ b/t/lib/filehand.t @@ -14,7 +14,7 @@ use FileHandle; use strict subs; $mystdout = new_from_fd FileHandle 1,"w"; -autoflush STDOUT; +$| = 1; autoflush $mystdout; print "1..4\n"; @@ -24,12 +24,6 @@ $fh = new FileHandle "TEST", O_RDONLY and print "ok 2\n"; $buffer = <$fh>; print $buffer eq "#!./perl\n" ? "ok 3\n" : "not ok 3\n"; -if ($^O eq 'VMS') { - ungetc $fh 65; - CORE::read($fh, $buf,1); -} -else { - ungetc STDIN 65; - CORE::read(STDIN, $buf,1); -} +ungetc $fh 65; +CORE::read($fh, $buf,1); print $buf eq 'A' ? "ok 4\n" : "not ok 4\n";