summaryrefslogtreecommitdiffstats
path: root/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
diff options
context:
space:
mode:
authorMarc Mutz <marc.mutz@kdab.com>2016-08-05 10:04:11 +0300
committerMarc Mutz <marc.mutz@kdab.com>2016-08-06 14:49:09 +0000
commitc0b6e16ffa0edf0ed76cfdfeb71ec3aae99c98dd (patch)
treea01337a47f4860490f819e5a58bf3f799cfebd5c /tests/auto/corelib/global/qlogging/tst_qlogging.cpp
parent96317570efd959b9bcc0092ad65a3b228a75f5f1 (diff)
tests/auto/corelib/global: clean up
- port Q_FOREACH to C++11 range-for (except in the Q_FOREACH tests :) - port uses of inefficient QLists to QVector - include QTest, not QtTest Fixes some errors pointed out by my tree's static checks. Change-Id: Ibb21a280537af74dda5679ec7c75d59477b6de55 Reviewed-by: David Faure <david.faure@kdab.com>
Diffstat (limited to 'tests/auto/corelib/global/qlogging/tst_qlogging.cpp')
-rw-r--r--tests/auto/corelib/global/qlogging/tst_qlogging.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
index ce227a6c8b..c2d7338042 100644
--- a/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
+++ b/tests/auto/corelib/global/qlogging/tst_qlogging.cpp
@@ -30,7 +30,7 @@
#include <qdebug.h>
#include <qglobal.h>
#include <QtCore/QProcess>
-#include <QtTest/QtTest>
+#include <QtTest/QTest>
class tst_qmessagehandler : public QObject
{
@@ -841,7 +841,7 @@ void tst_qmessagehandler::qMessagePattern()
QVERIFY(!output.isEmpty());
QCOMPARE(!output.contains("QT_MESSAGE_PATTERN"), valid);
- foreach (const QByteArray &e, expected) {
+ for (const QByteArray &e : qAsConst(expected)) {
if (!output.contains(e)) {
qDebug() << output;
qDebug() << "expected: " << e;