diff --git a/Lib/test/test_import.py b/Lib/test/test_import.py index c72bca041ba..f209d1b5b5a 100644 --- a/Lib/test/test_import.py +++ b/Lib/test/test_import.py @@ -156,7 +156,7 @@ class ImportTests(unittest.TestCase): m2 = __import__(TESTFN) self.assertEqual(m2.x, 'rewritten') # Now delete the source file and check the pyc was rewritten - unlink(TESTFN) + unlink(fname) unload(TESTFN) m3 = __import__(TESTFN) self.assertEqual(m3.x, 'rewritten')