RegressionTests__ExternalStreamTest.st
changeset 139 2734294aa8f2
parent 138 cf36235e4ce0
child 140 4bd3d40bb165
--- a/RegressionTests__ExternalStreamTest.st	Tue Dec 18 20:50:55 2001 +0100
+++ b/RegressionTests__ExternalStreamTest.st	Tue Dec 18 20:55:39 2001 +0100
@@ -62,6 +62,31 @@
     "
 !
 
+testPosition2
+    |h s|
+
+    self createWithSize10:'xxx3'.
+
+    h := OperatingSystem openFileForRead:'xxx3'.
+    s := ExternalReadStream on:h.
+
+    self assert:( s atEnd not ).
+    self assert:( s position == 0 ).
+
+    s setToEnd.
+
+    self assert:( s position == 10 ).
+    self assert:( s atEnd ).
+
+    s close.
+
+    'xxx3' asFilename delete.
+
+    "
+     self new testPosition2
+    "
+!
+
 testRead1
     "open an existing file for reading; should read 10 chars"