commit | 938f635acb65873a55adeae8f1e5351b3ac5ea74 | [log] [tgz] |
---|---|---|
author | Victor Stinner <victor.stinner@haypocalc.com> | Thu Jun 30 18:25:07 2011 +0200 |
committer | Victor Stinner <victor.stinner@haypocalc.com> | Thu Jun 30 18:25:07 2011 +0200 |
tree | 2fbd1550aff1511ddb31003504ab924d69bec87a | |
parent | 2f655b73e4903a218e09cb4c58f7a2b8a706582a [diff] [blame] |
Issue #12451: Open the test file in binary mode in test_bz2, the text file is not needed.
diff --git a/Lib/test/test_bz2.py b/Lib/test/test_bz2.py index 75078be..5a7d342 100644 --- a/Lib/test/test_bz2.py +++ b/Lib/test/test_bz2.py
@@ -340,7 +340,7 @@ def testFileno(self): self.createTempFile() - with open(self.filename) as rawf: + with open(self.filename, 'rb') as rawf: with BZ2File(fileobj=rawf) as bz2f: self.assertEqual(bz2f.fileno(), rawf.fileno())