aboutsummaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorHugo Parente Lima <hugo.pl@gmail.com>2011-03-23 19:14:42 -0300
committerHugo Parente Lima <hugo.pl@gmail.com>2012-03-08 16:54:05 -0300
commit61f479b6826f7d88c02c0ab5986e8e2c08be5518 (patch)
tree9b0b83f643e49bfb6587e1348477fc6557c4dd49 /tests
parente360a53087975cac53975f00e747991b7eb818af (diff)
Fix bug 699 - "PySide.QtCore.Property doesn't throw a TypeError if the first arg isn't a PyType."
Diffstat (limited to 'tests')
-rw-r--r--tests/QtCore/CMakeLists.txt1
-rw-r--r--tests/QtCore/bug_699.py17
2 files changed, 18 insertions, 0 deletions
diff --git a/tests/QtCore/CMakeLists.txt b/tests/QtCore/CMakeLists.txt
index 434c8fe83..48de2c4bb 100644
--- a/tests/QtCore/CMakeLists.txt
+++ b/tests/QtCore/CMakeLists.txt
@@ -6,6 +6,7 @@ PYSIDE_TEST(bug_462.py)
PYSIDE_TEST(bug_505.py)
PYSIDE_TEST(bug_515.py)
PYSIDE_TEST(bug_656.py)
+PYSIDE_TEST(bug_699.py)
PYSIDE_TEST(bug_706.py)
PYSIDE_TEST(blocking_signals_test.py)
PYSIDE_TEST(child_event_test.py)
diff --git a/tests/QtCore/bug_699.py b/tests/QtCore/bug_699.py
new file mode 100644
index 000000000..e731b5be2
--- /dev/null
+++ b/tests/QtCore/bug_699.py
@@ -0,0 +1,17 @@
+import unittest
+from PySide.QtCore import *
+
+class TestBug699 (unittest.TestCase):
+
+ def defClass(self):
+ class Foo (QObject):
+ def foo(self):
+ pass
+
+ prop = Property(foo, foo)
+
+ def testIt(self):
+ self.assertRaises(TypeError, self.defClass)
+
+if __name__ == '__main__':
+ unittest.main()