diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2016-06-13 06:24:11 (GMT) |
---|---|---|
committer | Serhiy Storchaka <storchaka@gmail.com> | 2016-06-13 06:24:11 (GMT) |
commit | 8acb568c8863e9b7d0f52df42a0677688afc0988 (patch) | |
tree | e76010be89cf8513798a200356c2bf36728179f7 /Lib/tkinter/test | |
parent | dffd42f1301271e2fec386732d3459771eec3cd5 (diff) | |
download | cpython-8acb568c8863e9b7d0f52df42a0677688afc0988.zip cpython-8acb568c8863e9b7d0f52df42a0677688afc0988.tar.gz cpython-8acb568c8863e9b7d0f52df42a0677688afc0988.tar.bz2 |
Issue #27025: Generated names for Tkinter widgets are now more meanful
and recognizirable.
Diffstat (limited to 'Lib/tkinter/test')
-rw-r--r-- | Lib/tkinter/test/test_tkinter/test_misc.py | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/tkinter/test/test_tkinter/test_misc.py b/Lib/tkinter/test/test_tkinter/test_misc.py index 85ee2c7..9dc1e37 100644 --- a/Lib/tkinter/test/test_tkinter/test_misc.py +++ b/Lib/tkinter/test/test_tkinter/test_misc.py @@ -12,6 +12,14 @@ class MiscTest(AbstractTkTest, unittest.TestCase): f = tkinter.Frame(t, name='child') self.assertEqual(repr(f), '<tkinter.Frame object .top.child>') + def test_generated_names(self): + t = tkinter.Toplevel(self.root) + f = tkinter.Frame(t) + f2 = tkinter.Frame(t) + b = tkinter.Button(f2) + for name in str(b).split('.'): + self.assertFalse(name.isidentifier(), msg=repr(name)) + def test_tk_setPalette(self): root = self.root root.tk_setPalette('black') |