[Python-checkins] r73097 - python/branches/tk_and_idle_maintenance/Lib/lib-tk/test/test_tkinter/test_text.py

guilherme.polo python-checkins at python.org
Mon Jun 1 04:59:40 CEST 2009


Author: guilherme.polo
Date: Mon Jun  1 04:59:39 2009
New Revision: 73097

Log:
Checking for invalid index.

Modified:
   python/branches/tk_and_idle_maintenance/Lib/lib-tk/test/test_tkinter/test_text.py

Modified: python/branches/tk_and_idle_maintenance/Lib/lib-tk/test/test_tkinter/test_text.py
==============================================================================
--- python/branches/tk_and_idle_maintenance/Lib/lib-tk/test/test_tkinter/test_text.py	(original)
+++ python/branches/tk_and_idle_maintenance/Lib/lib-tk/test/test_tkinter/test_text.py	Mon Jun  1 04:59:39 2009
@@ -28,6 +28,9 @@
         self.assertEqual(len(bbox), 4)
         self.assertEqual(bbox, self.text.bbox('1.0 -1c +1c'))
 
+        # Invalid index.
+        self.assertRaises(Tkinter.TclError, self.text.bbox, '1,0')
+
         # The following used to raise Tkinter.TclError since text.bbox allowed
         # passing multiple args.
         self.assertRaises(TypeError, self.text.bbox, '1.0', '-1c')


More information about the Python-checkins mailing list