diff options
| author | Michael Foord <fuzzyman@voidspace.org.uk> | 2009-06-02 18:22:38 (GMT) |
|---|---|---|
| committer | Michael Foord <fuzzyman@voidspace.org.uk> | 2009-06-02 18:22:38 (GMT) |
| commit | 48bc8203cceb893e7e1d765350dedc8ba783f343 (patch) | |
| tree | 91c3f8119a6a6d07056c36a2bd20adb35cf8b77f /Lib/unittest.py | |
| parent | 05f26d88fd545d9057ca6a5f993862d1ba5850f7 (diff) | |
| download | cpython-48bc8203cceb893e7e1d765350dedc8ba783f343.zip cpython-48bc8203cceb893e7e1d765350dedc8ba783f343.tar.gz cpython-48bc8203cceb893e7e1d765350dedc8ba783f343.tar.bz2 | |
Restore default testRunner argument in unittest.main to None. Issue 6177.
Diffstat (limited to 'Lib/unittest.py')
| -rw-r--r-- | Lib/unittest.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/Lib/unittest.py b/Lib/unittest.py index 09c6ca9..2ad5de7 100644 --- a/Lib/unittest.py +++ b/Lib/unittest.py @@ -798,8 +798,10 @@ Examples: in MyTestCase """ def __init__(self, module='__main__', defaultTest=None, - argv=None, testRunner=TextTestRunner, + argv=None, testRunner=None, testLoader=defaultTestLoader): + if testRunner is None: + testRunner = TextTestRunner if type(module) == type(''): self.module = __import__(module) for part in module.split('.')[1:]: |
