diff options
author | Johan Dahlin <jdahlin@async.com.br> | 2005-08-24 17:29:09 +0000 |
---|---|---|
committer | Johan Dahlin <johan@src.gnome.org> | 2005-08-24 17:29:09 +0000 |
commit | 329297f101a6135c103b5d2d8cad9ec7527605af (patch) | |
tree | 42f61d3a80fc7f5ea31f4883152637d674a0e633 | |
parent | d9b0169ad2b312d0776b3a2a03d93e8d91049f75 (diff) | |
download | pygobject-329297f101a6135c103b5d2d8cad9ec7527605af.tar.gz |
Add test for Table.attach which takes uint arguments.
2005-08-24 Johan Dahlin <jdahlin@async.com.br>
* tests/test_conversion.py (Tests.testUIntArg): Add test for
Table.attach which takes uint arguments.
* codegen/argtypes.py (UIntArg.write_param):
One more take on fixing #300012, this time unsigned int conversion,
patch by Gustavo.
-rw-r--r-- | tests/test_conversion.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/test_conversion.py b/tests/test_conversion.py index 72dc5c42..373ab9d1 100644 --- a/tests/test_conversion.py +++ b/tests/test_conversion.py @@ -1,5 +1,7 @@ # -*- Mode: Python -*- +import sys + import unittest from common import gtk, gobject @@ -69,5 +71,15 @@ class Tests(unittest.TestCase): c = gtk.gdk.Color(pixel=0xffffffffL) self.assertEqual(c.pixel, 0xffffffffL) + def testUIntArg(self): + child = gtk.DrawingArea() + table = gtk.Table(2, 2, False) + table.attach(child, 1, 2, 0, 1, ypadding=2) + self.assertEqual(table.child_get_property(child, 'y-padding'), 2) + + child = gtk.DrawingArea() + table.attach(child, 1, 2, 0, 1, ypadding=2L) + self.assertEqual(table.child_get_property(child, 'y-padding'), 2) + if __name__ == '__main__': unittest.main() |