From a0a62225094a890c1b07ebc4f89e4c7c45c66b13 Mon Sep 17 00:00:00 2001 From: Tim Peters Date: Sun, 9 Sep 2001 06:12:01 +0000 Subject: Teach regrtest how to pass on doctest failure msgs. This is done via a horridly inefficient hack in regrtest's Compare class, but it's about as clean as can be: regrtest has to set up the Compare instance before importing a test module, and by the time the module *is* imported it's too late to change that decision. The good news is that the more tests we convert to unittest and doctest, the less the inefficiency here matters. Even now there are few tests with large expected-output files (the new cost here is a Python-level call per .write() when there's an expected- output file). --- Lib/test/test_difflib.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'Lib/test/test_difflib.py') diff --git a/Lib/test/test_difflib.py b/Lib/test/test_difflib.py index 3b2f8213bc..9c63d9ad1d 100644 --- a/Lib/test/test_difflib.py +++ b/Lib/test/test_difflib.py @@ -1,3 +1,2 @@ -from test_support import verbose -import doctest, difflib -doctest.testmod(difflib, verbose=verbose) +import difflib, test_support +test_support.run_doctest(difflib) -- cgit v1.2.1