make FileIO.mode always include 'b'

#4386 Reviewed by Amaury
This commit is contained in:
Benjamin Peterson 2008-11-22 00:41:45 +00:00
parent 656aa28cd5
commit 44309e6b37
8 changed files with 24 additions and 16 deletions

View file

@ -150,7 +150,7 @@ class TestGzip(unittest.TestCase):
def test_mode(self):
self.test_write()
f = gzip.GzipFile(self.filename, 'r')
self.assertTrue(f.myfileobj.mode.startswith('r'))
self.assertEqual(f.myfileobj.mode, 'rb')
f.close()
def test_1647484(self):