[Python-checkins] cpython (merge 3.5 -> default): Merge: Revise and synchronize idle_test.test_configdialog.
terry.reedy
python-checkins at python.org
Sat Jun 4 15:56:12 EDT 2016
https://hg.python.org/cpython/rev/f5d243646fd4
changeset: 101712:f5d243646fd4
parent: 101710:e672cf63d08a
parent: 101711:ab974f1ebebe
user: Terry Jan Reedy <tjreedy at udel.edu>
date: Sat Jun 04 15:55:53 2016 -0400
summary:
Merge: Revise and synchronize idle_test.test_configdialog.
files:
Lib/idlelib/idle_test/test_configdialog.py | 17 ++++-----
1 files changed, 8 insertions(+), 9 deletions(-)
diff --git a/Lib/idlelib/idle_test/test_configdialog.py b/Lib/idlelib/idle_test/test_configdialog.py
--- a/Lib/idlelib/idle_test/test_configdialog.py
+++ b/Lib/idlelib/idle_test/test_configdialog.py
@@ -1,21 +1,21 @@
'''Test idlelib.configdialog.
-Coverage: 46% just by creating dialog. The other half is change code.
+Coverage: 46% just by creating dialog.
+The other half is code for working with user customizations.
'''
+from idlelib.configdialog import ConfigDialog # always test import
+from test.support import requires
+requires('gui')
+from tkinter import Tk
import unittest
-from test.support import requires
-from tkinter import Tk
-from idlelib.configdialog import ConfigDialog
-from idlelib.macosx import _initializeTkVariantTests
-
+from idlelib import macosx
class ConfigDialogTest(unittest.TestCase):
@classmethod
def setUpClass(cls):
- requires('gui')
cls.root = Tk()
- _initializeTkVariantTests(cls.root)
+ macosx._initializeTkVariantTests(cls.root)
@classmethod
def tearDownClass(cls):
@@ -26,7 +26,6 @@
def test_dialog(self):
d = ConfigDialog(self.root, 'Test', _utest=True)
d.remove_var_callbacks()
- d.destroy()
if __name__ == '__main__':
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list