perl 3.0 patch #22 patch #19, continued
[p5sagit/p5-mst-13.2.git] / t / op.read
CommitLineData
a687059c 1#!./perl
2
3# $Header: op.read,v 3.0 89/10/18 15:30:58 lwall Locked $
4
5print "1..4\n";
6
7
8open(FOO,'op.read') || open(FOO,'t/op.read') || die "Can't open op.read";
9seek(FOO,4,0);
10$got = read(FOO,$buf,4);
11
12print ($got == 4 ? "ok 1\n" : "not ok 1\n");
13print ($buf eq "perl" ? "ok 2\n" : "not ok 2 :$buf:\n");
14
15seek(FOO,20000,0);
16$got = read(FOO,$buf,4);
17
18print ($got == 0 ? "ok 3\n" : "not ok 3\n");
19print ($buf eq "" ? "ok 4\n" : "not ok 4\n");