summaryrefslogtreecommitdiffstats
path: root/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp')
-rw-r--r--tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp b/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
index 10d7aa20f8..6b2df3cce4 100644
--- a/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
+++ b/tests/auto/network/access/qnetworkcookiejar/tst_qnetworkcookiejar.cpp
@@ -518,7 +518,7 @@ void tst_QNetworkCookieJar::rfc6265_data()
QVERIFY(!document.isNull());
QVERIFY(document.isArray());
- foreach (const QJsonValue& testCase, document.array()) {
+ for (const QJsonValue testCase : document.array()) {
QJsonObject testObject = testCase.toObject();
//"test" - the test case name
@@ -527,15 +527,15 @@ void tst_QNetworkCookieJar::rfc6265_data()
continue;
//"received" - the cookies received from the server
- QJsonArray received = testObject.value("received").toArray();
+ const QJsonArray received = testObject.value("received").toArray();
QStringList receivedList;
- foreach (const QJsonValue& receivedCookie, received)
+ for (const QJsonValue receivedCookie : received)
receivedList.append(receivedCookie.toString());
//"sent" - the cookies sent back to the server
- QJsonArray sent = testObject.value("sent").toArray();
+ const QJsonArray sent = testObject.value("sent").toArray();
QList<QNetworkCookie> sentList;
- foreach (const QJsonValue& sentCookie, sent) {
+ for (const QJsonValue sentCookie : sent) {
QJsonObject sentCookieObject = sentCookie.toObject();
QNetworkCookie cookie;
cookie.setName(sentCookieObject.value("name").toString().toUtf8());