summaryrefslogtreecommitdiffstats
path: root/tests/QtGui/bug_300_test.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/QtGui/bug_300_test.py')
-rw-r--r--tests/QtGui/bug_300_test.py17
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/QtGui/bug_300_test.py b/tests/QtGui/bug_300_test.py
new file mode 100644
index 00000000..ec02cdf0
--- /dev/null
+++ b/tests/QtGui/bug_300_test.py
@@ -0,0 +1,17 @@
+from PySide.QtGui import QStringListModel
+from PySide.QtCore import QModelIndex
+import unittest
+
+class TestQAbstractItemModelSignals(unittest.TestCase):
+ def sigCallback(self, index, r, c):
+ self._called = True
+
+ def testSignals(self):
+ self._called = False
+ m = QStringListModel()
+ m.rowsAboutToBeInserted[QModelIndex,int,int].connect(self.sigCallback)
+ m.insertRows(0, 3)
+ self.assert_(self._called)
+
+if __name__ == '__main__':
+ unittest.main()