summaryrefslogtreecommitdiffstats
path: root/Lib/lib-tk/test/test_ttk/test_widgets.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/lib-tk/test/test_ttk/test_widgets.py')
-rw-r--r--Lib/lib-tk/test/test_ttk/test_widgets.py12
1 files changed, 2 insertions, 10 deletions
diff --git a/Lib/lib-tk/test/test_ttk/test_widgets.py b/Lib/lib-tk/test/test_ttk/test_widgets.py
index f0777ab..4b01364 100644
--- a/Lib/lib-tk/test/test_ttk/test_widgets.py
+++ b/Lib/lib-tk/test/test_ttk/test_widgets.py
@@ -461,10 +461,7 @@ class EntryTest(AbstractWidgetTest, unittest.TestCase):
def test_bbox(self):
- self.assertEqual(len(self.entry.bbox(0)), 4)
- for item in self.entry.bbox(0):
- self.assertIsInstance(item, int)
-
+ self.assertIsBoundingBox(self.entry.bbox(0))
self.assertRaises(Tkinter.TclError, self.entry.bbox, 'noindex')
self.assertRaises(Tkinter.TclError, self.entry.bbox, None)
@@ -1217,12 +1214,7 @@ class TreeviewTest(AbstractWidgetTest, unittest.TestCase):
self.assertTrue(children)
bbox = self.tv.bbox(children[0])
- self.assertEqual(len(bbox), 4)
- self.assertIsInstance(bbox, tuple)
- for item in bbox:
- if not isinstance(item, int):
- self.fail("Invalid bounding box: %s" % bbox)
- break
+ self.assertIsBoundingBox(bbox)
# compare width in bboxes
self.tv['columns'] = ['test']