diff options
author | Victor Stinner <vstinner@python.org> | 2021-03-23 01:11:31 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-23 01:11:31 +0100 |
commit | 30793e81bd90f3346e962435d49073bc588f067c (patch) | |
tree | 58e4b646c5e58f03e4e78ae7ecda5a992b5cd70d /Lib/test/libregrtest/setup.py | |
parent | 0473fb222956063814b6beb5fd401f9eeaa8a56a (diff) | |
download | cpython-git-30793e81bd90f3346e962435d49073bc588f067c.tar.gz |
bpo-41718: Disable support.testresult XML output by default (GH-24982)
RegressionTestResult.USE_XML must now be set to True to get the JUnit
XML output.
Reduce the number of imports when --junit-xml=FILE option is not
used: 153 => 144 (-9).
Diffstat (limited to 'Lib/test/libregrtest/setup.py')
-rw-r--r-- | Lib/test/libregrtest/setup.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/libregrtest/setup.py b/Lib/test/libregrtest/setup.py index 7738d4f28b..715d4b96cf 100644 --- a/Lib/test/libregrtest/setup.py +++ b/Lib/test/libregrtest/setup.py @@ -93,6 +93,10 @@ def setup_tests(ns): support.SHORT_TIMEOUT = min(support.SHORT_TIMEOUT, ns.timeout) support.LONG_TIMEOUT = min(support.LONG_TIMEOUT, ns.timeout) + if ns.xmlpath: + from test.support.testresult import RegressionTestResult + RegressionTestResult.USE_XML = True + def replace_stdout(): """Set stdout encoder error handler to backslashreplace (as stderr error |