[New-bugs-announce] [issue17303] Fix test discovery for test_future*

Zachary Ware report at bugs.python.org
Tue Feb 26 22:38:25 CET 2013


New submission from Zachary Ware:

Here's the fix for test discovery of test_future* (particularly test_future3).  Without the patch, running 'python -m unittest discover Lib/test/ "test_future*"' results in an error in test_future3.py, due to test_future.py's FutureTest.test_future3 removing test_future3 from sys.modules by way of support.unload.  The patch replaces all instances of support.unload with a support.CleanImport context manager.

The patch also replaces test_main() in all test_future*.py modules, just for good measure.

----------
components: Tests
files: test_future_discovery.diff
keywords: patch
messages: 183092
nosy: brett.cannon, ezio.melotti, zach.ware
priority: normal
severity: normal
status: open
title: Fix test discovery for test_future*
type: behavior
versions: Python 3.3, Python 3.4
Added file: http://bugs.python.org/file29252/test_future_discovery.diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue17303>
_______________________________________


More information about the New-bugs-announce mailing list