testinggtk r285 - trunk/tests
- From: bjornl svn gnome org
- To: svn-commits-list gnome org
- Subject: testinggtk r285 - trunk/tests
- Date: Sat, 28 Jun 2008 11:12:49 +0000 (UTC)
Author: bjornl
Date: Sat Jun 28 11:12:49 2008
New Revision: 285
URL: http://svn.gnome.org/viewvc/testinggtk?rev=285&view=rev
Log:
Tests for orientation enhancement in #442042
Modified:
trunk/tests/test_scalebutton.py
Modified: trunk/tests/test_scalebutton.py
==============================================================================
--- trunk/tests/test_scalebutton.py (original)
+++ trunk/tests/test_scalebutton.py Sat Jun 28 11:12:49 2008
@@ -10,3 +10,27 @@
assert sb.get_property('icons') == []
assert sb.get_property('size') == gtk.ICON_SIZE_INVALID
assert sb.get_property('value') == 0
+
+def test_orientation_property():
+ '''
+ Ensure that ``gtk.ScaleButton`` has an ``orientation`` property
+ and that it is set to ``gtk.ORIENTATION_VERTICAL`` by default.
+
+ :bug: #442042
+ '''
+ sb = gtk.ScaleButton(gtk.ICON_SIZE_INVALID, 0, 100, 2)
+ assert sb.get_property('orientation') == gtk.ORIENTATION_VERTICAL
+
+def test_set_orientation_property():
+ '''
+ Ensure that ``gtk.ScaleButton``:s ``orientation`` property can not
+ be modified.
+
+ :bug: #442042
+ '''
+ sb = gtk.ScaleButton(gtk.ICON_SIZE_INVALID, 0, 100, 2)
+ try:
+ sb.set_property('orientation', gtk.ORIENTATION_VERTICAL)
+ assert False
+ except TypeError:
+ assert True
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]