[docs] [issue7061] Improve 24.5. turtle doc

Alexander Belopolsky report at bugs.python.org
Fri Nov 5 15:43:44 CET 2010


Alexander Belopolsky <belopolsky at users.sourceforge.net> added the comment:

On Fri, Nov 5, 2010 at 3:34 AM, Georg Brandl <report at bugs.python.org> wrote:
..
> Why shouldn't global function doctests be runnable?

They should - I just couldn't figure out a better hack that would work
for both mathods and functions.  Note that functions are
auto-generated in turtle from Screen and Turtle methods.  The doctests
are just method doctests with turtle. or screen. prefix dropped.  In
order to remove dependency between doctests, I create a new turtle for
each test and assign it to global "turtle" variable.  For some reason
similar approach did not work for functions.  I'll keep trying,
though.

On the other hand, since function doctests are auto-generated from
method doctests, there is little to be gained from running them
separately.

----------

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


More information about the docs mailing list