summaryrefslogtreecommitdiffstats
path: root/tests/auto/testlib/selftests/warnings
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/testlib/selftests/warnings')
-rw-r--r--tests/auto/testlib/selftests/warnings/CMakeLists.txt1
-rw-r--r--tests/auto/testlib/selftests/warnings/tst_warnings.cpp2
2 files changed, 3 insertions, 0 deletions
diff --git a/tests/auto/testlib/selftests/warnings/CMakeLists.txt b/tests/auto/testlib/selftests/warnings/CMakeLists.txt
index 12ccea5f5b..553a023a90 100644
--- a/tests/auto/testlib/selftests/warnings/CMakeLists.txt
+++ b/tests/auto/testlib/selftests/warnings/CMakeLists.txt
@@ -7,6 +7,7 @@
qt_internal_add_executable(warnings
NO_INSTALL
+ EXCEPTIONS
OUTPUT_DIRECTORY ${CMAKE_CURRENT_BINARY_DIR}
SOURCES
tst_warnings.cpp
diff --git a/tests/auto/testlib/selftests/warnings/tst_warnings.cpp b/tests/auto/testlib/selftests/warnings/tst_warnings.cpp
index 3dd9a7afe2..174e496cd0 100644
--- a/tests/auto/testlib/selftests/warnings/tst_warnings.cpp
+++ b/tests/auto/testlib/selftests/warnings/tst_warnings.cpp
@@ -1,6 +1,7 @@
// Copyright (C) 2020 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GPL-3.0-only WITH Qt-GPL-exception-1.0
+#undef QTEST_THROW_ON_FAILURE // fails ### investigate
#include <QtCore/QCoreApplication>
#include <QtCore/QRegularExpression>
@@ -183,6 +184,7 @@ void tst_Warnings::testFailOnWarningsWithData()
void tst_Warnings::testFailOnWarningsFailInHelper()
{
+ const QTest::ThrowOnFailDisabler nothrow; // tests repeated QFAILs
[](){ QFAIL("This failure message should be printed but not cause the test to abort"); }();
// So we've already failed, but we get more messages - that don't increment counters.
const auto warnRegex = QRegularExpression("Ran out of .*!");