summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorJohan Dahlin <johan@src.gnome.org>2007-01-20 14:12:03 +0000
committerJohan Dahlin <johan@src.gnome.org>2007-01-20 14:12:03 +0000
commitbc87216d1f7942e41d32b75af30f782f520d9b42 (patch)
tree52b135439bf63cfe95d4f71d25c78a3beb31f9ab /tests
parent6d47d90b4d93b95a30f0b4815745f34b8dce92c9 (diff)
downloadpygtk-bc87216d1f7942e41d32b75af30f782f520d9b42.tar.gz
Add a display refcounting test
svn path=/trunk/; revision=2805
Diffstat (limited to 'tests')
-rw-r--r--tests/test_gdk.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/tests/test_gdk.py b/tests/test_gdk.py
index 9d3d7fd7..95b23794 100644
--- a/tests/test_gdk.py
+++ b/tests/test_gdk.py
@@ -46,3 +46,13 @@ class GdkTest(unittest.TestCase):
'\x00\x01',
1,
[0xdeadbe, 0xbebabe])
+
+ def testDisplay(self):
+ gc.collect()
+ display = gtk.gdk.Display(None)
+ del display
+ self.assertEquals(gc.collect(), 1)
+ display = gtk.gdk.Display(None)
+ display.close()
+ del display
+ #self.assertEquals(gc.collect(), 1)