Closes #12291 for 3.3 - merged fix from 3.2.

This commit is contained in:
Vinay Sajip 2011-07-02 17:16:02 +01:00
commit 65897a386e
4 changed files with 183 additions and 60 deletions

View file

@ -214,7 +214,7 @@ class BadBytecodeTest(unittest.TestCase):
lambda bc: bc[:8] + b'<test>',
del_source=del_source)
file_path = mapping['_temp'] if not del_source else bytecode_path
with self.assertRaises(ValueError):
with self.assertRaises(EOFError):
self.import_(file_path, '_temp')
def _test_bad_magic(self, test, *, del_source=False):