[pygobject] Add unit test for the TreeModelSort override
- From: Paolo Borelli <pborelli src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [pygobject] Add unit test for the TreeModelSort override
- Date: Wed, 15 Aug 2012 11:29:45 +0000 (UTC)
commit ee6da6f1aa2cd6e55834f9edc17f785613d00031
Author: Paolo Borelli <pborelli gnome org>
Date: Wed Aug 15 13:16:11 2012 +0200
Add unit test for the TreeModelSort override
tests/test_overrides.py | 7 +++++++
1 files changed, 7 insertions(+), 0 deletions(-)
---
diff --git a/tests/test_overrides.py b/tests/test_overrides.py
index 3990454..6e32f49 100644
--- a/tests/test_overrides.py
+++ b/tests/test_overrides.py
@@ -932,6 +932,13 @@ class TestGtk(unittest.TestCase):
self.tester.assertEqual(int_value, self.int_value)
self.tester.assertEqual(string_value, self.string_value)
+ def test_tree_model_sort(self):
+ self.assertEqual(Gtk.TreeModelSort, overrides.Gtk.TreeModelSort)
+ self.assertRaises(TypeError, Gtk.TreeModelSort)
+ model = Gtk.TreeStore(int, bool)
+ model_sort = Gtk.TreeModelSort(model)
+ self.assertEqual(model_sort.get_model(), model)
+
def test_tree_store(self):
self.assertEqual(Gtk.TreeStore, overrides.Gtk.TreeStore)
self.assertEqual(Gtk.ListStore, overrides.Gtk.ListStore)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]