summaryrefslogtreecommitdiffstats
path: root/Lib/test/support
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2018-12-14 12:06:50 (GMT)
committerGitHub <noreply@github.com>2018-12-14 12:06:50 (GMT)
commit3a8f4fef4a4dd0e4a800545468eef9542e126181 (patch)
tree381684b45c5485d95fd32dda185431ecc3aedc1c /Lib/test/support
parent7acd50ad8b2a4fe132f7b26980ed3cd209b7ea12 (diff)
downloadcpython-3a8f4fef4a4dd0e4a800545468eef9542e126181.zip
cpython-3a8f4fef4a4dd0e4a800545468eef9542e126181.tar.gz
cpython-3a8f4fef4a4dd0e4a800545468eef9542e126181.tar.bz2
bpo-34279: regrtest consider that skipped tests are ran (GH-11132)
bpo-34279, bpo-35412: support.run_unittest() no longer raises TestDidNotRun if a test result contains skipped tests. The exception is now only raised if no test have been run and no test have been skipped.
Diffstat (limited to 'Lib/test/support')
-rw-r--r--Lib/test/support/__init__.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/Lib/test/support/__init__.py b/Lib/test/support/__init__.py
index 05e8593..9b6c338 100644
--- a/Lib/test/support/__init__.py
+++ b/Lib/test/support/__init__.py
@@ -1937,7 +1937,7 @@ def _run_suite(suite):
if junit_xml_list is not None:
junit_xml_list.append(result.get_xml_element())
- if not result.testsRun:
+ if not result.testsRun and not result.skipped:
raise TestDidNotRun
if not result.wasSuccessful():
if len(result.errors) == 1 and not result.failures: