Issue #27196: Stop 'application destroyed' warnings when running IDLE tests.

The update_idletasks solution was provided by Serhiy Storchaka.
This commit is contained in:
Terry Jan Reedy 2016-06-03 23:53:56 -04:00
parent 75cbeb5dac
commit 6047b55372
5 changed files with 22 additions and 10 deletions

View file

@ -1,6 +1,8 @@
"""Test idlelib.ParenMatch."""
# This must currently be a gui test because ParenMatch methods use
# several text methods not defined on idlelib.idle_test.mock_tk.Text.
'''Test idlelib.ParenMatch.
This must currently be a gui test because ParenMatch methods use
several text methods not defined on idlelib.idle_test.mock_tk.Text.
'''
from test.support import requires
requires('gui')
@ -29,6 +31,7 @@ class ParenMatchTest(unittest.TestCase):
@classmethod
def tearDownClass(cls):
del cls.text, cls.editwin
cls.root.update_idletasks()
cls.root.destroy()
del cls.root