summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_file.py
diff options
context:
space:
mode:
authorMartin v. Löwis <martin@v.loewis.de>2002-06-11 06:22:31 (GMT)
committerMartin v. Löwis <martin@v.loewis.de>2002-06-11 06:22:31 (GMT)
commitf90ae20354ceb501f0ba0b6459df17f1a8005a47 (patch)
treef9aae742cfa33ba10af2ed8152aff802430f626c /Lib/test/test_file.py
parent7981ce576c719e291dc901a3463e725b6be3c50e (diff)
downloadcpython-f90ae20354ceb501f0ba0b6459df17f1a8005a47.zip
cpython-f90ae20354ceb501f0ba0b6459df17f1a8005a47.tar.gz
cpython-f90ae20354ceb501f0ba0b6459df17f1a8005a47.tar.bz2
Patch #488073: AtheOS port.
Diffstat (limited to 'Lib/test/test_file.py')
-rw-r--r--Lib/test/test_file.py7
1 files changed, 6 insertions, 1 deletions
diff --git a/Lib/test/test_file.py b/Lib/test/test_file.py
index 71222c1..261db2c 100644
--- a/Lib/test/test_file.py
+++ b/Lib/test/test_file.py
@@ -1,3 +1,4 @@
+import sys
import os
from array import array
@@ -88,7 +89,11 @@ f.close()
if not f.closed:
raise TestFailed, 'file.closed should be true'
-for methodname in ['fileno', 'flush', 'isatty', 'read', 'readinto', 'readline', 'readlines', 'seek', 'tell', 'truncate', 'write', 'xreadlines' ]:
+methods = ['fileno', 'flush', 'isatty', 'read', 'readinto', 'readline', 'readlines', 'seek', 'tell', 'truncate', 'write', 'xreadlines' ]
+if sys.platform.startswith('atheos'):
+ methods.remove('truncate')
+
+for methodname in methods:
method = getattr(f, methodname)
try:
method()