[Python-checkins] cpython (merge 3.5 -> default): Issue #24408: Fixed test for tkinter.Font on OS X.
serhiy.storchaka
python-checkins at python.org
Sun Jun 21 13:44:19 CEST 2015
https://hg.python.org/cpython/rev/2d072d07dfe2
changeset: 96626:2d072d07dfe2
parent: 96622:7e46a503dd16
parent: 96625:5b037f934e40
user: Serhiy Storchaka <storchaka at gmail.com>
date: Sun Jun 21 14:43:15 2015 +0300
summary:
Issue #24408: Fixed test for tkinter.Font on OS X.
Based on patch by Martin Panter.
files:
Lib/tkinter/test/test_tkinter/test_font.py | 11 +++++++++-
1 files changed, 10 insertions(+), 1 deletions(-)
diff --git a/Lib/tkinter/test/test_tkinter/test_font.py b/Lib/tkinter/test/test_tkinter/test_font.py
--- a/Lib/tkinter/test/test_tkinter/test_font.py
+++ b/Lib/tkinter/test/test_tkinter/test_font.py
@@ -75,10 +75,19 @@
def test_families(self):
families = font.families(self.root)
- self.assertIn(self.font.actual('family'), families)
+ self.assertIsInstance(families, tuple)
+ self.assertTrue(families)
+ for family in families:
+ self.assertIsInstance(family, str)
+ self.assertTrue(family)
def test_names(self):
names = font.names(self.root)
+ self.assertIsInstance(names, tuple)
+ self.assertTrue(names)
+ for name in names:
+ self.assertIsInstance(name, str)
+ self.assertTrue(name)
self.assertIn(fontname, names)
tests_gui = (FontTest, )
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list