[Python-checkins] cpython (2.7): Issue #XXXXX: Fix test_idle so that idlelib test cases are actually run
terry.reedy
python-checkins at python.org
Mon Nov 4 05:48:04 CET 2013
http://hg.python.org/cpython/rev/cced7981ec4d
changeset: 86908:cced7981ec4d
branch: 2.7
user: Terry Jan Reedy <tjreedy at udel.edu>
date: Sun Nov 03 23:37:54 2013 -0500
summary:
Issue #XXXXX: Fix test_idle so that idlelib test cases are actually run
under test.regrtest on 2.7.
files:
Lib/test/test_idle.py | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/Lib/test/test_idle.py b/Lib/test/test_idle.py
--- a/Lib/test/test_idle.py
+++ b/Lib/test/test_idle.py
@@ -23,6 +23,10 @@
# load_tests() if it finds it. (Unittest.main does the same.)
load_tests = idletest.load_tests
+# pre-3.3 regrtest does not support the load_tests protocol. use test_main
+def test_main():
+ support.run_unittest(unittest.TestLoader().loadTestsFromModule(idletest))
+
if __name__ == '__main__':
# Until unittest supports resources, we emulate regrtest's -ugui
# so loaded tests run the same as if textually present here.
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list