testinggtk r122 - trunk/tests



Author: bjornl
Date: Sun Jun  8 22:42:57 2008
New Revision: 122
URL: http://svn.gnome.org/viewvc/testinggtk?rev=122&view=rev

Log:
Extend test_toplevel_in_window test with the case when the widgets direct parent is somehting other than the gtk.Window

Modified:
   trunk/tests/test_widget.py

Modified: trunk/tests/test_widget.py
==============================================================================
--- trunk/tests/test_widget.py	(original)
+++ trunk/tests/test_widget.py	Sun Jun  8 22:42:57 2008
@@ -32,6 +32,15 @@
     win.add(widget)
     assert widget.get_toplevel() == win
 
+    # The window should be the toplevel even if it is not the widgets
+    # direct parent.
+    win = gtk.Window()
+    widget = gtk.Button()
+    box = gtk.HBox()
+    box.add(widget)
+    win.add(box)
+    assert widget.get_toplevel() == win
+
 @utils.pass_on_warnings
 def test_realize_not_anchred_widget():
     '''



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