diff options
author | Edward Loper <edloper@gradient.cis.upenn.edu> | 2004-08-26 01:41:51 (GMT) |
---|---|---|
committer | Edward Loper <edloper@gradient.cis.upenn.edu> | 2004-08-26 01:41:51 (GMT) |
commit | 71f55af826481576ffa75f9dc0771e20ab7c1187 (patch) | |
tree | 911ebe23b50d2e1c83a12a77a61eabe220c04585 /Lib/test/test_doctest.py | |
parent | 5662929a4268efdeed21c45366e6a632926a275f (diff) | |
download | cpython-71f55af826481576ffa75f9dc0771e20ab7c1187.zip cpython-71f55af826481576ffa75f9dc0771e20ab7c1187.tar.gz cpython-71f55af826481576ffa75f9dc0771e20ab7c1187.tar.bz2 |
Renamed UNIFIED_DIFF->REPORT_UDIFF; CONTEXT_DIFF->REPORT_CDIFF; and
NDIFF_DIFF->REPORT_NDIFF. This establishes the naming convention that
all reporting options should begin with "REPORT_" (since reporting
options are a different class from output comparison options; but they
are both set in optionflags).
Diffstat (limited to 'Lib/test/test_doctest.py')
-rw-r--r-- | Lib/test/test_doctest.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/Lib/test/test_doctest.py b/Lib/test/test_doctest.py index 29c3ec2..d683051 100644 --- a/Lib/test/test_doctest.py +++ b/Lib/test/test_doctest.py @@ -923,7 +923,7 @@ output to match any substring in the actual output: ... # doctest: +NORMALIZE_WHITESPACE [0, 1, ..., 18, 19] -The UNIFIED_DIFF flag causes failures that involve multi-line expected +The REPORT_UDIFF flag causes failures that involve multi-line expected and actual outputs to be displayed using a unified diff: >>> def f(x): @@ -965,7 +965,7 @@ and actual outputs to be displayed using a unified diff: >>> # With the flag: >>> test = doctest.DocTestFinder().find(f)[0] - >>> flags = doctest.UNIFIED_DIFF + >>> flags = doctest.REPORT_UDIFF >>> doctest.DocTestRunner(verbose=False, optionflags=flags).run(test) ********************************************************************** Line 2, in f @@ -985,12 +985,12 @@ and actual outputs to be displayed using a unified diff: <BLANKLINE> (1, 1) -The CONTEXT_DIFF flag causes failures that involve multi-line expected +The REPORT_CDIFF flag causes failures that involve multi-line expected and actual outputs to be displayed using a context diff: - >>> # Reuse f() from the UNIFIED_DIFF example, above. + >>> # Reuse f() from the REPORT_UDIFF example, above. >>> test = doctest.DocTestFinder().find(f)[0] - >>> flags = doctest.CONTEXT_DIFF + >>> flags = doctest.REPORT_CDIFF >>> doctest.DocTestRunner(verbose=False, optionflags=flags).run(test) ********************************************************************** Line 2, in f @@ -1019,7 +1019,7 @@ and actual outputs to be displayed using a context diff: (1, 1) -The NDIFF_DIFF flag causes failures to use the difflib.Differ algorithm +The REPORT_NDIFF flag causes failures to use the difflib.Differ algorithm used by the popular ndiff.py utility. This does intraline difference marking, as well as interline differences. @@ -1029,7 +1029,7 @@ marking, as well as interline differences. ... a b c d e f g h i j k 1 m ... ''' >>> test = doctest.DocTestFinder().find(f)[0] - >>> flags = doctest.NDIFF_DIFF + >>> flags = doctest.REPORT_NDIFF >>> doctest.DocTestRunner(verbose=False, optionflags=flags).run(test) ********************************************************************** Line 2, in f |