summaryrefslogtreecommitdiffstats
path: root/tests/test_subtype.py
diff options
context:
space:
mode:
authorJohan Dahlin <johan@src.gnome.org>2004-09-27 15:59:13 +0000
committerJohan Dahlin <johan@src.gnome.org>2004-09-27 15:59:13 +0000
commitb4205323655072faef3e0d86a219c374ef9535b3 (patch)
treebfadf3957e1c252b24110d9468ac0ac785f5a867 /tests/test_subtype.py
parentaa2fc4070b361e679a219e3c1e9dc75dd3acfb9d (diff)
downloadpygobject-b4205323655072faef3e0d86a219c374ef9535b3.tar.gz
pygobject-b4205323655072faef3e0d86a219c374ef9535b3.tar.xz
pygobject-b4205323655072faef3e0d86a219c374ef9535b3.zip
Revert parts of Gustavos changes, so the size of interfaces are correct.
* codegen/codegen.py (FileOutput.resetline): Revert parts of Gustavos changes, so the size of interfaces are correct. * tests/test_subtype.py: tests for this.
Diffstat (limited to 'tests/test_subtype.py')
-rw-r--r--tests/test_subtype.py13
1 files changed, 13 insertions, 0 deletions
diff --git a/tests/test_subtype.py b/tests/test_subtype.py
new file mode 100644
index 0000000..6a13b31
--- /dev/null
+++ b/tests/test_subtype.py
@@ -0,0 +1,13 @@
+import unittest
+
+from common import gobject, gtk
+
+class TestSubType(unittest.TestCase):
+ def testSubType(self):
+ t = type('testtype', (gobject.GObject, gobject.GInterface), {})
+ assert issubclass(t, gobject.GObject)
+ assert issubclass(t, gobject.GInterface)
+ t = type('testtype2', (gobject.GObject, gtk.TreeModel), {})
+ assert issubclass(t, gobject.GObject)
+ assert issubclass(t, gtk.TreeModel)
+