[Python-checkins] cpython (merge 3.2 -> default): Issue #13645: fix test_import failure when run immediately after test_coding.
antoine.pitrou
python-checkins at python.org
Wed Dec 21 15:54:22 CET 2011
http://hg.python.org/cpython/rev/a6bd166abde5
changeset: 74113:a6bd166abde5
parent: 74111:bd3631f9aa5c
parent: 74112:f4afc6858ed2
user: Antoine Pitrou <solipsis at pitrou.net>
date: Wed Dec 21 15:53:16 2011 +0100
summary:
Issue #13645: fix test_import failure when run immediately after test_coding.
files:
Lib/test/test_import.py | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
diff --git a/Lib/test/test_import.py b/Lib/test/test_import.py
--- a/Lib/test/test_import.py
+++ b/Lib/test/test_import.py
@@ -104,8 +104,9 @@
try:
fname = TESTFN + os.extsep + "py"
create_empty_file(fname)
+ fn = imp.cache_from_source(fname)
+ unlink(fn)
__import__(TESTFN)
- fn = imp.cache_from_source(fname)
if not os.path.exists(fn):
self.fail("__import__ did not result in creation of "
"either a .pyc or .pyo file")
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list