cpython (2.7): Issue #15392: Use test.test_support, as used test.support in 3.x.
http://hg.python.org/cpython/rev/6159916c712e changeset: 83989:6159916c712e branch: 2.7 parent: 83986:93eb15779050 user: Terry Jan Reedy <tjreedy@udel.edu> date: Thu May 30 18:24:28 2013 -0400 summary: Issue #15392: Use test.test_support, as used test.support in 3.x. files: Lib/test/test_idle.py | 11 ++++------- 1 files changed, 4 insertions(+), 7 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 @@ -1,11 +1,8 @@ # Skip test if _tkinter or _thread wasn't built or idlelib was deleted. -try: - import Tkinter - import threading # imported by PyShell, imports _thread - import idlelib.idle_test as idletest -except ImportError: - import unittest - raise unittest.SkipTest +from test.test_support import import_module +import_module('Tkinter') +import_module('threading') # imported by PyShell, imports _thread +idletest = import_module('idlelib.idle_test') # Without test_main present, regrtest.runtest_inner (line1219) calls # unittest.TestLoader().loadTestsFromModule(this_module) which calls -- Repository URL: http://hg.python.org/cpython
participants (1)
-
terry.reedy