testinggtk r437 - trunk/tests
- From: bjornl svn gnome org
- To: svn-commits-list gnome org
- Subject: testinggtk r437 - trunk/tests
- Date: Tue, 9 Sep 2008 19:11:01 +0000 (UTC)
Author: bjornl
Date: Tue Sep 9 19:11:00 2008
New Revision: 437
URL: http://svn.gnome.org/viewvc/testinggtk?rev=437&view=rev
Log:
Test that the scrolled windows scrollbars are None in __init__ if constructed using gobject.new
Modified:
trunk/tests/test_scrolledwindow.py
Modified: trunk/tests/test_scrolledwindow.py
==============================================================================
--- trunk/tests/test_scrolledwindow.py (original)
+++ trunk/tests/test_scrolledwindow.py Tue Sep 9 19:11:00 2008
@@ -50,6 +50,20 @@
gobject.type_register(MyScrolledWindow)
gobject.new(MyScrolledWindow)
+def test_scrollbars_in_subclass_init():
+ '''
+ Ensure that the scrolled windows scrollbars are ``None`` within a
+ subclass __init__ method.
+ '''
+ class Test124(gtk.ScrolledWindow):
+ def __init__(self):
+ super(Test124, self).__init__()
+ print 'yes'
+ assert not self.get_hscrollbar()
+ assert not self.get_vscrollbar()
+ gobject.type_register(Test124)
+ gobject.new(Test124)
+
@utils.pass_on_warnings
def test_add_non_scrollable_widget():
'''
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]