testinggtk r339 - trunk/tests



Author: bjornl
Date: Thu Jul 17 02:40:33 2008
New Revision: 339
URL: http://svn.gnome.org/viewvc/testinggtk?rev=339&view=rev

Log:
Test the can-focus property

Modified:
   trunk/tests/test_widget.py

Modified: trunk/tests/test_widget.py
==============================================================================
--- trunk/tests/test_widget.py	(original)
+++ trunk/tests/test_widget.py	Thu Jul 17 02:40:33 2008
@@ -141,6 +141,14 @@
     widget.set_flags(gtk.NO_WINDOW)
     assert widget.flags() & gtk.NO_WINDOW
 
+def test_set_get_can_focus():
+    widget = gtk.Button()
+    assert widget.get_property('can-focus')
+    widget.set_property('can-focus', False)
+    assert not widget.get_property('can-focus')
+    widget.set_property('can-focus', True)
+    assert widget.get_property('can-focus')
+
 def test_grab_add():
     '''
     Ensure that when a widget is made the current grabbing widget,



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]