diff options
Diffstat (limited to 'tests/qtgui/qapplication_exit_segfault_test.py')
-rw-r--r-- | tests/qtgui/qapplication_exit_segfault_test.py | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/tests/qtgui/qapplication_exit_segfault_test.py b/tests/qtgui/qapplication_exit_segfault_test.py new file mode 100644 index 000000000..72b810a98 --- /dev/null +++ b/tests/qtgui/qapplication_exit_segfault_test.py @@ -0,0 +1,17 @@ + +import unittest +import sys + +from PySide.QtGui import QApplication, QPushButton, QWidget, QSpinBox + +class QApplicationDelete(unittest.TestCase): + '''Test for segfault when deleting a QApplication before a QWidget''' + + def testQPushButton(self): + #QApplication deleted before QPushButton + a = QApplication([]) + b = QPushButton('aaaa') + del a + +if __name__ == '__main__': + unittest.main() |