[issue8048] doctest assumes sys.displayhook hasn't been touched

Noam Yorav-Raphael report at bugs.python.org
Thu Mar 4 23:00:46 CET 2010


Noam Yorav-Raphael <noamraph at gmail.com> added the comment:

Ok, here's a patch (against current svn of Python 2) with a test case.

I had to fix three tests which combined pdb and doctest, since now, when run under doctest, pdb steps into the displayhook because it's a Python function and not a built-in function. The fix is just to return from the displayhook.

If you wish, I can prepare a patch for Python 3.

----------
Added file: http://bugs.python.org/file16436/diff

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue8048>
_______________________________________


More information about the Python-bugs-list mailing list