[Python-3000-checkins] r59353 - python/branches/py3k/Lib/test/test_io.py
christian.heimes
python-3000-checkins at python.org
Wed Dec 5 14:24:28 CET 2007
Author: christian.heimes
Date: Wed Dec 5 14:24:28 2007
New Revision: 59353
Modified:
python/branches/py3k/Lib/test/test_io.py
Log:
Fixed line separator problem on Windows
Modified: python/branches/py3k/Lib/test/test_io.py
==============================================================================
--- python/branches/py3k/Lib/test/test_io.py (original)
+++ python/branches/py3k/Lib/test/test_io.py Wed Dec 5 14:24:28 2007
@@ -528,13 +528,13 @@
t = io.TextIOWrapper(b, encoding="ascii", errors="ignore")
t.write("abc\xffdef\n")
t.flush()
- self.assertEquals(b.getvalue(), b"abcdef\n")
+ self.assertEquals(b.getvalue(), b"abcdef" + os.linesep.encode())
# (4) replace
b = io.BytesIO()
t = io.TextIOWrapper(b, encoding="ascii", errors="replace")
t.write("abc\xffdef\n")
t.flush()
- self.assertEquals(b.getvalue(), b"abc?def\n")
+ self.assertEquals(b.getvalue(), b"abc?def" + os.linesep.encode())
def testNewlinesInput(self):
testdata = b"AAA\nBBB\nCCC\rDDD\rEEE\r\nFFF\r\nGGG"
More information about the Python-3000-checkins
mailing list