summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/qdialog/tst_qdialog.cpp8
1 files changed, 7 insertions, 1 deletions
diff --git a/tests/auto/qdialog/tst_qdialog.cpp b/tests/auto/qdialog/tst_qdialog.cpp
index 86f87b8..8b6aee6 100644
--- a/tests/auto/qdialog/tst_qdialog.cpp
+++ b/tests/auto/qdialog/tst_qdialog.cpp
@@ -447,7 +447,7 @@ void tst_QDialog::deleteInExec()
}
#ifndef QT_NO_EXCEPTIONS
-class QDialogTestException { };
+class QDialogTestException : public std::exception { };
class ExceptionDialog : public QDialog
{
@@ -471,11 +471,17 @@ void tst_QDialog::throwInExec()
try {
ExceptionDialog dialog;
QMetaObject::invokeMethod(&dialog, "throwException", Qt::QueuedConnection);
+ QMetaObject::invokeMethod(&dialog, "reject", Qt::QueuedConnection);
(void) dialog.exec();
} catch(...) {
++caughtExceptions;
}
+#ifdef Q_OS_SYMBIAN
+ //on symbian, the event loop absorbs exceptions
+ QCOMPARE(caughtExceptions, 0);
+#else
QCOMPARE(caughtExceptions, 1);
+#endif
}
#else
void tst_QDialog::throwInExec()