testinggtk r452 - trunk/tests
- From: bjornl svn gnome org
- To: svn-commits-list gnome org
- Subject: testinggtk r452 - trunk/tests
- Date: Wed, 10 Sep 2008 21:48:49 +0000 (UTC)
Author: bjornl
Date: Wed Sep 10 21:48:49 2008
New Revision: 452
URL: http://svn.gnome.org/viewvc/testinggtk?rev=452&view=rev
Log:
Add tc for the packing options for a buttons label and image widget
Modified:
trunk/tests/test_button.py
Modified: trunk/tests/test_button.py
==============================================================================
--- trunk/tests/test_button.py (original)
+++ trunk/tests/test_button.py Wed Sep 10 21:48:49 2008
@@ -152,3 +152,25 @@
# b1.add(b2)
# b2.add(b3)
# b3.add(b1)
+
+def test_child_packing_in_image_button():
+ '''
+ Ensure that the packing settings of a buttons label and image
+ widgets are correct.
+ '''
+ button = gtk.Button('text', gtk.STOCK_ADD)
+ box = button.get_child().get_child()
+
+ child1 = box.get_children()[0]
+ expand, fill, padding, pack_type = box.query_child_packing(child1)
+ assert expand == 0
+ assert fill == 0
+ assert padding == 0
+ assert pack_type == gtk.PACK_START
+
+ child2 = box.get_children()[1]
+ expand, fill, padding, pack_type = box.query_child_packing(child2)
+ assert expand == 0
+ assert fill == 0
+ assert padding == 0
+ assert pack_type == gtk.PACK_END
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]