mirror of
https://github.com/python/cpython.git
synced 2025-07-30 06:34:15 +00:00
Restore default testRunner argument in unittest.main to None. Issue 6177
This commit is contained in:
parent
abb4ec6dc4
commit
dad7b7b1cb
2 changed files with 11 additions and 1 deletions
|
@ -1640,9 +1640,11 @@ class TestProgram(object):
|
|||
"""
|
||||
USAGE = USAGE
|
||||
def __init__(self, module='__main__', defaultTest=None,
|
||||
argv=None, testRunner=TextTestRunner,
|
||||
argv=None, testRunner=None,
|
||||
testLoader=defaultTestLoader, exit=True,
|
||||
verbosity=1):
|
||||
if testRunner is None:
|
||||
testRunner = TextTestRunner
|
||||
if isinstance(module, basestring):
|
||||
self.module = __import__(module)
|
||||
for part in module.split('.')[1:]:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue