From: Antoine Pitrou <solipsis@pitrou.net>
Date: Mon, 15 Sep 2008 23:54:52 +0000 (+0000)
Subject: Fix Windows buildbot failures after r66469.
X-Git-Tag: v3.0rc1~7
X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=d62269f9207ca9ac539c9216a9b41cab4f62d5e4;p=python

Fix Windows buildbot failures after r66469.
---

diff --git a/Lib/test/test_os.py b/Lib/test/test_os.py
index f58aaf7911..4897aaf713 100644
--- a/Lib/test/test_os.py
+++ b/Lib/test/test_os.py
@@ -69,7 +69,8 @@ class FileTests(unittest.TestCase):
         os.write(fd, memoryview(b"spam\n"))
         os.close(fd)
         with open(support.TESTFN, "rb") as fobj:
-            self.assertEqual(fobj.read(), b"bacon\neggs\nspam\n")
+            self.assertEqual(fobj.read().splitlines(),
+                [b"bacon", b"eggs", b"spam"])
 
 
 class TemporaryFileTests(unittest.TestCase):
diff --git a/Lib/test/test_tempfile.py b/Lib/test/test_tempfile.py
index 0e5cb0f2d1..0ef0925ee0 100644
--- a/Lib/test/test_tempfile.py
+++ b/Lib/test/test_tempfile.py
@@ -314,7 +314,7 @@ class test__mkstemp_inner(TC):
         if not has_textmode:
             return            # ugh, can't use TestSkipped.
 
-        self.do_create(bin=0).write("blat\n")
+        self.do_create(bin=0).write(b"blat\n")
         # XXX should test that the file really is a text file
 
 test_classes.append(test__mkstemp_inner)