summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorRenato Araujo Oliveira Filho <renato.filho@openbossa.org>2010-12-15 17:52:29 -0300
committerRenato Araujo Oliveira Filho <renato.filho@openbossa.org>2010-12-15 19:06:45 -0300
commit539b906eb241b3874d015695bffd072632783960 (patch)
treea905f1edc939cb557e77f35af3034c9ba49c06ed /tests
parentfd9c8c8d7684a2ae9b6bee7521a1b28e2cdefa45 (diff)
downloadpyside-539b906eb241b3874d015695bffd072632783960.tar.gz
pyside-539b906eb241b3874d015695bffd072632783960.tar.xz
pyside-539b906eb241b3874d015695bffd072632783960.zip
Created function used in PyObject getAttro.
Moved the code generated to a function in libpyside. Create unit test for bug #525. Reviewer: Hugo Parente Lima <hugo.pl@gmail.com> Marcelo Lira <marcelo.lira@openbossa.org>
Diffstat (limited to 'tests')
-rw-r--r--tests/QtGui/CMakeLists.txt1
-rw-r--r--tests/QtGui/bug_525.py21
2 files changed, 22 insertions, 0 deletions
diff --git a/tests/QtGui/CMakeLists.txt b/tests/QtGui/CMakeLists.txt
index 4bfb0d5..7cde60f 100644
--- a/tests/QtGui/CMakeLists.txt
+++ b/tests/QtGui/CMakeLists.txt
@@ -20,6 +20,7 @@ PYSIDE_TEST(bug_467.py)
PYSIDE_TEST(bug_480.py)
PYSIDE_TEST(bug_500.py)
PYSIDE_TEST(bug_512.py)
+PYSIDE_TEST(bug_525.py)
PYSIDE_TEST(customproxywidget_test.py)
PYSIDE_TEST(deepcopy_test.py)
PYSIDE_TEST(float_to_int_implicit_conversion_test.py)
diff --git a/tests/QtGui/bug_525.py b/tests/QtGui/bug_525.py
new file mode 100644
index 0000000..5e146eb
--- /dev/null
+++ b/tests/QtGui/bug_525.py
@@ -0,0 +1,21 @@
+import unittest
+from PySide.QtGui import QApplication
+from PySide.QtGui import QMenu
+
+class M2(QMenu):
+ def __init__(self,parent=None):
+ super(M2,self).__init__(parent)
+ self.setTitle(self.tr("M2"))
+
+class TestMenuDerivedClass(unittest.TestCase):
+ def aboutToShowHandler(self):
+ pass
+
+ def testConnectSignal(self):
+ app = QApplication([])
+ m2 = M2()
+ # Test if the aboutToShow signal was translated to correct type
+ m2.aboutToShow.connect(self.aboutToShowHandler)
+
+if __name__ == '__main__':
+ unittest.main()