By the way, I copied this 2006-10 clp issue into Bugs.python.org. --
Pat LaVarre
""" http://bugs.python.org/issue1611
TITLE: doctest.testmod gets noisy if called more than once per
SystemExit
SUMMARY:
Calling doctest.testmod more than once before SystemExit spews stderr
messages such as "*** Do
> ... every run of doctest after the first is verbose ...
> *** DocTestRunner.merge: '__main__' in both testers; summing outcomes.
Another path to the same bug:
import doctest
print doctest.testfile(__file__, verbose=False)
print doctest.testfile(__file__, verbose=False)
Mystifiedly yours, rank
Looks like every run of doctest after the first is verbose:
$ python2.5 quiet-once.py
(0, 0)
*** DocTestRunner.merge: '__main__' in both testers; summing outcomes.
(0, 0)
*** DocTestRunner.merge: '__main__' in both testers; summing outcomes.
(0, 0)
$
$ cat quiet-once.py
import doctest
print doctes