summaryrefslogtreecommitdiffstats
path: root/src/testlib/qtestlog.cpp
diff options
context:
space:
mode:
authorSona Kurazyan <sona.kurazyan@qt.io>2022-04-26 16:33:09 +0200
committerSona Kurazyan <sona.kurazyan@qt.io>2022-04-28 11:15:11 +0200
commit79cf895c700f2a700479eae10cf538d0860e1d29 (patch)
tree8b32cd14f396e922faf855751290f22a0ea8a355 /src/testlib/qtestlog.cpp
parentc038fa9e774d8531ccb975e6ca1541358830847e (diff)
QtTestLib: stop using QLatin1Char constructor for creating char literals
Required for porting away from QLatin1Char/QLatin1String in scope of QTBUG-98434. Change-Id: I3debae5f481037958bfb65caabca97a0d4681eb9 Reviewed-by: Edward Welbourne <edward.welbourne@qt.io>
Diffstat (limited to 'src/testlib/qtestlog.cpp')
-rw-r--r--src/testlib/qtestlog.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/testlib/qtestlog.cpp b/src/testlib/qtestlog.cpp
index 4f0e3a43bc..e87527e57a 100644
--- a/src/testlib/qtestlog.cpp
+++ b/src/testlib/qtestlog.cpp
@@ -148,7 +148,7 @@ namespace QTest {
// ignore an optional whitespace at the end of str
// (the space was added automatically by ~QDebug() until Qt 5.3,
// so autotests still might expect it)
- if (expected.endsWith(QLatin1Char(' ')))
+ if (expected.endsWith(u' '))
return actual == QStringView{expected}.left(expected.length() - 1);
return false;
@@ -328,10 +328,10 @@ void QTestLog::printUnhandledIgnoreMessages()
QTest::IgnoreResultList *list = QTest::ignoreResultList;
while (list) {
if (list->pattern.userType() == QMetaType::QString) {
- message = QStringLiteral("Did not receive message: \"") + list->pattern.toString() + QLatin1Char('"');
+ message = QStringLiteral("Did not receive message: \"") + list->pattern.toString() + u'"';
} else {
#if QT_CONFIG(regularexpression)
- message = QStringLiteral("Did not receive any message matching: \"") + list->pattern.toRegularExpression().pattern() + QLatin1Char('"');
+ message = QStringLiteral("Did not receive any message matching: \"") + list->pattern.toRegularExpression().pattern() + u'"';
#endif
}
FOREACH_TEST_LOGGER