diff options
author | R David Murray <rdmurray@bitdance.com> | 2013-06-23 18:24:13 (GMT) |
---|---|---|
committer | R David Murray <rdmurray@bitdance.com> | 2013-06-23 18:24:13 (GMT) |
commit | 5707d508e1b589045ce1062da3497ad9653f1cf6 (patch) | |
tree | bc2ba43038f5011301e09cf2e78c213f2b3e6114 /Doc/library/doctest.rst | |
parent | c00fffb659bc69666ba05025057e762cf24e76b0 (diff) | |
download | cpython-5707d508e1b589045ce1062da3497ad9653f1cf6.zip cpython-5707d508e1b589045ce1062da3497ad9653f1cf6.tar.gz cpython-5707d508e1b589045ce1062da3497ad9653f1cf6.tar.bz2 |
#11390: convert doctest CLI to argparse and add -o and -f options.
This provides a way to specify arbitrary doctest options when using
the CLI interface to process test files, just as one can when calling
testmod or testfile programmatically.
Diffstat (limited to 'Doc/library/doctest.rst')
-rw-r--r-- | Doc/library/doctest.rst | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/Doc/library/doctest.rst b/Doc/library/doctest.rst index 200de45..6138e30 100644 --- a/Doc/library/doctest.rst +++ b/Doc/library/doctest.rst @@ -495,7 +495,10 @@ Option Flags A number of option flags control various aspects of doctest's behavior. Symbolic names for the flags are supplied as module constants, which can be or'ed together and passed to various functions. The names can also be used in -:ref:`doctest directives <doctest-directives>`. +:ref:`doctest directives <doctest-directives>`, and may be passed to the +doctest command line interface via the ``-o`` option. + +.. versionadded:: 3.4 the ``-o`` command line option The first group of options define test semantics, controlling aspects of how doctest decides whether actual output matches an example's expected output: @@ -640,6 +643,9 @@ The second group of options controls how test failures are reported: 1. This flag may be useful during debugging, since examples after the first failure won't even produce debugging output. + The doctest command line accepts the option ``-f`` as a shorthand for ``-o + FAIL_FAST``. + .. versionadded:: 3.4 |