gh-117294: Report DocTestCase as skipped if all examples in the doctest are skipped (GH-117297)

This commit is contained in:
Malcolm Smith 2024-03-28 19:59:12 +00:00 committed by GitHub
parent efcc96844e
commit 29829b58a8
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
7 changed files with 87 additions and 7 deletions

View file

@ -1021,7 +1021,8 @@ from text files and modules with doctests:
and runs the interactive examples in each file. If an example in any file
fails, then the synthesized unit test fails, and a :exc:`failureException`
exception is raised showing the name of the file containing the test and a
(sometimes approximate) line number.
(sometimes approximate) line number. If all the examples in a file are
skipped, then the synthesized unit test is also marked as skipped.
Pass one or more paths (as strings) to text files to be examined.
@ -1087,7 +1088,8 @@ from text files and modules with doctests:
and runs each doctest in the module. If any of the doctests fail, then the
synthesized unit test fails, and a :exc:`failureException` exception is raised
showing the name of the file containing the test and a (sometimes approximate)
line number.
line number. If all the examples in a docstring are skipped, then the
synthesized unit test is also marked as skipped.
Optional argument *module* provides the module to be tested. It can be a module
object or a (possibly dotted) module name. If not specified, the module calling