summaryrefslogtreecommitdiffstats
path: root/src/plugins/sqldrivers/mysql/qsql_mysql.cpp
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@qt.io>2025-08-29 17:25:39 +0200
committerMarc Mutz <marc.mutz@qt.io>2025-09-17 16:42:19 +0200
commit5bde0225c81137dccc197006a88501d9a4e7024a (patch)
tree821249d0f0157c30627b839c979d198c690059f9 /src/plugins/sqldrivers/mysql/qsql_mysql.cpp
parent73e13a88f7e966ebeb2db276642710bf51a6f1bb (diff)
Make QTEST_THROW_ON_FAIL work from within QtConcurrent
QtConcurrent rewrites any exception that doesn't inherit QException into a QUnhandledException, incl. QtTest's internal TestFailedException class (ditto for skipped). At the exit from a test function, QtTest therefore no longer recognizes the exceptions as its own, and lets them escape, or logs them as unexpected. Fix by inheriting the exceptions from QException, but QtConcurrent should really be fixed to use exception_ptr and not rely on Q(Unhandled)Exception. Add a check to tst_selftests. [ChangeLog][QtTest] Fixed a bug which prevented QTEST_THROW_ON_FAIL and QTEST_THROW_ON_SKIP from working with QCOMPARE(), QVERIFY(), and QSKIP() invoked from within QtConcurrent functions. Amends e769cf026e328ed7fff660c204ce6e55b80114e3. Pick-to: 6.10 6.9 6.8 Fixes: QTBUG-139765 Change-Id: I087c9fd49dbde22098e3ff173b8f843c120667b4 Reviewed-by: Øystein Heskestad <oystein.heskestad@qt.io> Reviewed-by: Ivan Solovev <ivan.solovev@qt.io>
Diffstat (limited to 'src/plugins/sqldrivers/mysql/qsql_mysql.cpp')
0 files changed, 0 insertions, 0 deletions