mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-09-04 18:30:36 +02:00
* sorted out tests
git-svn-id: trunk@43189 -
This commit is contained in:
parent
b02470468b
commit
6457846435
1
.gitattributes
vendored
1
.gitattributes
vendored
@ -17922,7 +17922,6 @@ tests/webtbs/tw4058.pp svneol=native#text/plain
|
|||||||
tests/webtbs/tw4068.pp svneol=native#text/plain
|
tests/webtbs/tw4068.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw4078.pp svneol=native#text/plain
|
tests/webtbs/tw4078.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw4080.pp svneol=native#text/plain
|
tests/webtbs/tw4080.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw40850.pp svneol=native#text/pascal
|
|
||||||
tests/webtbs/tw4086.pp svneol=native#text/plain
|
tests/webtbs/tw4086.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw4089.pp svneol=native#text/plain
|
tests/webtbs/tw4089.pp svneol=native#text/plain
|
||||||
tests/webtbs/tw4093.pp svneol=native#text/plain
|
tests/webtbs/tw4093.pp svneol=native#text/plain
|
||||||
|
@ -24,6 +24,8 @@ begin
|
|||||||
if EOF(test_file) then
|
if EOF(test_file) then
|
||||||
writeln('EOF reached');
|
writeln('EOF reached');
|
||||||
pos := filepos(test_file);
|
pos := filepos(test_file);
|
||||||
|
if pos<>9 then
|
||||||
|
halt(1);
|
||||||
writeln('File position: ', pos);
|
writeln('File position: ', pos);
|
||||||
read(test_file, my_bits);
|
read(test_file, my_bits);
|
||||||
writeln(my_bits);
|
writeln(my_bits);
|
||||||
|
@ -1,43 +0,0 @@
|
|||||||
{$mode iso}
|
|
||||||
program mytest;
|
|
||||||
|
|
||||||
procedure my_test1;
|
|
||||||
type byte_file = file of byte;
|
|
||||||
|
|
||||||
var test_file : byte_file;
|
|
||||||
test_text : text;
|
|
||||||
loc : integer;
|
|
||||||
len : integer;
|
|
||||||
my_bits : byte;
|
|
||||||
pos : int64;
|
|
||||||
begin
|
|
||||||
assign(test_text, 'tw40850.data');
|
|
||||||
rewrite(test_text);
|
|
||||||
write(test_text,'0123456789'#10);
|
|
||||||
close(test_text);
|
|
||||||
loc := 9;
|
|
||||||
assign(test_file, 'tw40850.data');
|
|
||||||
reset(test_file);
|
|
||||||
len := filesize(test_file);
|
|
||||||
writeln('File size: ', len);
|
|
||||||
seek(test_file, loc);
|
|
||||||
if EOF(test_file) then
|
|
||||||
writeln('EOF reached');
|
|
||||||
pos := filepos(test_file);
|
|
||||||
if pos<>9 then
|
|
||||||
halt(1);
|
|
||||||
writeln('File position: ', pos);
|
|
||||||
read(test_file, my_bits);
|
|
||||||
if my_bits<>57 then
|
|
||||||
halt(1);
|
|
||||||
writeln(my_bits);
|
|
||||||
read(test_file, my_bits);
|
|
||||||
writeln(my_bits);
|
|
||||||
if my_bits<>10 then
|
|
||||||
halt(1);
|
|
||||||
close(test_file);
|
|
||||||
writeln('ok');
|
|
||||||
end;
|
|
||||||
begin
|
|
||||||
my_test1;
|
|
||||||
end.
|
|
Loading…
Reference in New Issue
Block a user