diff options
author | Thiago Macieira <thiago.macieira@intel.com> | 2023-08-28 17:57:55 -0700 |
---|---|---|
committer | Thiago Macieira <thiago.macieira@intel.com> | 2023-08-30 23:26:25 -0700 |
commit | f1ba2b9f44964a0546da4815669cf728e50dd4a8 (patch) | |
tree | af2a5d09cb72a14b6dc9a8d8f6663a08b02244ac /tests/auto/testlib | |
parent | fcb548878bfae3db34d482f3ad97074aca76b410 (diff) |
tst_selftests: deduplicate the Unix/Linux conditions
Amends 118f2210c6279803b9a4103a796ce75e88f8beb2. That commit added
#ifdef Q_OS_UNIX
if (test == "assert"
|| test == "crashes"
|| test == "failfetchtype"
|| test == "faildatatype")
return; // Outputs "Received signal 6 (SIGABRT)"
#endif
Which duplicated 4 out of the 5 tests in the block:
#ifdef Q_OS_LINUX
// QEMU outputs to stderr about uncaught signals
if (QTestPrivate::isRunningArmOnX86() &&
(test == "assert"
|| test == "crashes"
|| test == "faildatatype"
|| test == "failfetchtype"
|| test == "silent"
))
return;
#endif
But as Linux is Unix, we never got to that second block for those 4
tests.
Pick-to: 6.6
Change-Id: I2b24e1d3cad44897906efffd177fb4b5507d190a
Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Diffstat (limited to 'tests/auto/testlib')
-rw-r--r-- | tests/auto/testlib/selftests/tst_selftests.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/tests/auto/testlib/selftests/tst_selftests.cpp b/tests/auto/testlib/selftests/tst_selftests.cpp index c95070a773..9787eec3b7 100644 --- a/tests/auto/testlib/selftests/tst_selftests.cpp +++ b/tests/auto/testlib/selftests/tst_selftests.cpp @@ -783,15 +783,10 @@ void checkErrorOutput(const QString &test, const QByteArray &errorOutput) #endif #ifdef Q_OS_LINUX - // QEMU outputs to stderr about uncaught signals - if (QTestPrivate::isRunningArmOnX86() && - (test == "assert" - || test == "crashes" - || test == "faildatatype" - || test == "failfetchtype" - || test == "silent" - )) - return; + if (test == "silent") { + if (QTestPrivate::isRunningArmOnX86()) + return; // QEMU outputs to stderr about uncaught signals + } #endif INFO(errorOutput.toStdString()); |