+ Test for append on devices.

git-svn-id: trunk@6787 -
This commit is contained in:
daniel 2007-03-11 18:56:02 +00:00
parent fd6fdfe896
commit 5784674f20
2 changed files with 24 additions and 0 deletions

1
.gitattributes vendored
View File

@ -6263,6 +6263,7 @@ tests/tbs/tb0527.pp svneol=native#text/plain
tests/tbs/tb0528.pp svneol=native#text/x-pascal
tests/tbs/tb0530.pp svneol=native#text/plain
tests/tbs/tb0531.pp svneol=native#text/plain
tests/tbs/tb0532.pp svneol=native#text/x-pascal
tests/tbs/ub0060.pp svneol=native#text/plain
tests/tbs/ub0069.pp svneol=native#text/plain
tests/tbs/ub0119.pp svneol=native#text/plain

23
tests/tbs/tb0532.pp Normal file
View File

@ -0,0 +1,23 @@
program tb0532;
{Append was the recommended way to open devices in TP.
A pitfall is that you cannot seek to the end of a device.
It has to work on modern platforms too, because:
- Rewrite will destroy the device on platforms where devices are
files.
- Reset doesn't allow writing to the device.
}
var null:text;
begin
{$ifdef Unix}
assign(null,'/dev/null');
{$else}
assign(null,'NUL');
{$endif}
append(null);
writeln(null,'Text disappearing into the black hole.');
close(null);
end.