Refs #23919 -- Replaced io.open() with open().

io.open() is an alias for open() on Python 3.
This commit is contained in:
Aymeric Augustin 2017-01-18 22:05:41 +01:00 committed by Tim Graham
parent eb422e476f
commit a556396339
11 changed files with 30 additions and 40 deletions

View file

@ -1370,7 +1370,7 @@ class FileBasedCacheTests(BaseCacheTests, TestCase):
self.assertEqual(cache.get('foo', 'baz'), 'baz')
def test_get_does_not_ignore_non_enoent_errno_values(self):
with mock.patch.object(io, 'open', side_effect=IOError):
with mock.patch('builtins.open', side_effect=IOError):
with self.assertRaises(IOError):
cache.get('foo')