summaryrefslogtreecommitdiffstats
path: root/tests
diff options
context:
space:
mode:
authorGiuseppe D'Angelo <giuseppe.dangelo@kdab.com>2022-02-01 17:02:19 +0100
committerQt Cherry-pick Bot <cherrypick_bot@qt-project.org>2022-02-05 11:10:22 +0000
commit543e7051ac07204846b3624508f67013aa8c6e91 (patch)
treed23366bb93135c46ba4a1692897f35134e631759 /tests
parentf96ca06b62963054f4e0716b1396a4282fedd17c (diff)
QPlainTestLogger: do not print "failure location" if there's no failure
When running a test under increased verbosity levels, QTestLib would print "failure location" for every QTest function (QVERIFY, QCOMPARE, ...), even if there's no failure at all. Keep the code centralized, but split the formatting of failures and non-failures (other messages). Task-number: QTBUG-96844 Change-Id: I3c508653176b68579dc0eb0cffcc153a52da2e2c Reviewed-by: Edward Welbourne <edward.welbourne@qt.io> Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io> (cherry picked from commit a605b9297d03943dbd7464f823460c9934aa2c31) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
Diffstat (limited to 'tests')
-rw-r--r--tests/auto/testlib/selftests/tst_selftests.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/tests/auto/testlib/selftests/tst_selftests.cpp b/tests/auto/testlib/selftests/tst_selftests.cpp
index 78b8e6ac3a..530414c326 100644
--- a/tests/auto/testlib/selftests/tst_selftests.cpp
+++ b/tests/auto/testlib/selftests/tst_selftests.cpp
@@ -220,6 +220,8 @@ bool compareOutput(const QString &logger, const QString &subdir,
continue;
if (actualLineBA.endsWith(" : failure location"))
continue;
+ if (actualLineBA.endsWith(" : message location"))
+ continue;
if (actualLineBA.startsWith("Config: Using QtTest library") // Text build string
|| actualLineBA.startsWith(" <QtBuild") // XML, Light XML build string