Message153503
While writing tests xml.etree, I hit a strange behaviour of import_fresh_module.
How to reproduce:
- dummy/__init__.py
- dummy/foo.py
- dummy/bar.py
- test_fresh_import.py
# 'dummy/foo.py'
from dummy.bar import func
# 'dummy/bar.py'
fortytwo = 42
def func():
assert fortytwo == 42
# 'test_fresh_import.py'
(see attachment)
# Output:
~ $ ./python.exe test_fresh_import.py
OK dummy.foo
OK dummy.bar
OK dummy.bar
OK dummy.foo
Traceback (most recent call last):
File "test_fresh_import.py", line 24, in <module>
test_fresh(m)
File "test_fresh_import.py", line 5, in test_fresh
rv = module.func()
File "./dummy/bar.py", line 6, in func
assert fortytwo == 42
AssertionError |
|
Date |
User |
Action |
Args |
2012-02-16 21:36:07 | flox | set | recipients:
+ flox, ncoghlan, eli.bendersky |
2012-02-16 21:36:07 | flox | set | messageid: <1329428167.53.0.868098431264.issue14035@psf.upfronthosting.co.za> |
2012-02-16 21:36:06 | flox | link | issue14035 messages |
2012-02-16 21:36:06 | flox | create | |
|