mirror of
https://github.com/python/cpython.git
synced 2025-07-28 21:55:21 +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
|
@ -3325,6 +3325,14 @@ class Test_TestProgram(TestCase):
|
|||
self.assertEqual(program.verbosity, 2)
|
||||
|
||||
|
||||
def testTestProgram_testRunnerArgument(self):
|
||||
program = object.__new__(TestProgram)
|
||||
program.parseArgs = lambda _: None
|
||||
program.runTests = lambda: None
|
||||
program.__init__(testRunner=None)
|
||||
self.assertEqual(program.testRunner, unittest.TextTestRunner)
|
||||
|
||||
|
||||
class FooBar(unittest.TestCase):
|
||||
def testPass(self):
|
||||
assert True
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue