[New-bugs-announce] [issue22629] Idle: update htest.py and hests

Terry J. Reedy report at bugs.python.org
Tue Oct 14 05:33:50 CEST 2014


New submission from Terry J. Reedy:

After using idle-test/htest.py and individual htests when editing files, a few updates are needed.

1. Improve the docstring for htest.py; add info about "# htest #" and #2 below.

2. Use Toplevel(parent) instead of Tk() for test-specific childs windows of the main, master window.  Currently, for some tests, such as CallTipWindow, the focus does not properly shift to the test window. Closing the master window first leaves the test window open.  Closing the test window second then causes several tcl errors (printed to console if available), a Windows message, and an Idle freeze of 5 seconds or more before Idle works again.  The change in this initial patch fixes the focus, non-close, error, and hang problems.  One click and the test window is ready to go; one click on the master and both go away.

3. Coding style issues -- I prefer to use winfo_rootx/y, as done elsewhere in Idle, to using re (close call).  For CallTipWindow, the inner class is not needed now, if it ever was.

----------
components: IDLE
files: @htest-34.diff
keywords: patch
messages: 229278
nosy: sahutd, terry.reedy
priority: normal
severity: normal
stage: patch review
status: open
title: Idle: update htest.py and hests
type: behavior
versions: Python 2.7, Python 3.4, Python 3.5
Added file: http://bugs.python.org/file36906/@htest-34.diff

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


More information about the New-bugs-announce mailing list