QPROPERTY_TEST_COMPARISON_HELPER: fix extra leading \n in failure output
Once we ported the formatting to use formatFailMessage() in aa8a4be9e9eae82b6c6b8875371114dbfb3ec06a, it became apparent that the output contained an extra leading newline compared QCOMPARE use of formatFailMessage(). We kept the newline in the patch that was picked to older branches. Since this is a stylistic discrepancy, though, standardize on no leading newline going forward. Change-Id: I4badf700900a106d835f3f72e92441d8a8912ff7 Reviewed-by: Ivan Solovev <ivan.solovev@qt.io> (cherry picked from commit 4bc81fe5d1d1e4587075a82a45be9b34825b5233) Reviewed-by: Qt Cherry-pick Bot <cherrypick_bot@qt-project.org>
This commit is contained in:
parent
a8a866b626
commit
9c3ab9a17e
@ -372,7 +372,7 @@ QTest::Internal::formatPropertyTestHelperFailure(char *msg, size_t maxMsgLen,
|
|||||||
const char *actual, const char *expected,
|
const char *actual, const char *expected,
|
||||||
const char *actualExpr, const char *expectedExpr)
|
const char *actualExpr, const char *expectedExpr)
|
||||||
{
|
{
|
||||||
formatFailMessage(msg, maxMsgLen, "\nComparison failed!", // ### why leading \n?
|
formatFailMessage(msg, maxMsgLen, "Comparison failed!",
|
||||||
actual, expected, actualExpr, expectedExpr,
|
actual, expected, actualExpr, expectedExpr,
|
||||||
QTest::ComparisonOperation::CustomCompare);
|
QTest::ComparisonOperation::CustomCompare);
|
||||||
return msg;
|
return msg;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user