summaryrefslogtreecommitdiff
path: root/tests/manual/websockets/tst_websockets.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/manual/websockets/tst_websockets.cpp')
-rw-r--r--tests/manual/websockets/tst_websockets.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/tests/manual/websockets/tst_websockets.cpp b/tests/manual/websockets/tst_websockets.cpp
index 8568532..6b327aa 100644
--- a/tests/manual/websockets/tst_websockets.cpp
+++ b/tests/manual/websockets/tst_websockets.cpp
@@ -152,12 +152,11 @@ void tst_WebSocketsTest::testLocalAddress()
void tst_WebSocketsTest::testPeerAddress()
{
QHostInfo hostInfo = QHostInfo::fromName(m_url.host());
- QList<QHostAddress> addresses = hostInfo.addresses();
+ const QList<QHostAddress> addresses = hostInfo.addresses();
QVERIFY(addresses.length() > 0);
QHostAddress peer = m_pWebSocket->peerAddress();
bool found = false;
- Q_FOREACH (const QHostAddress &a, addresses)
- {
+ for (const QHostAddress &a : addresses) {
if (a == peer)
{
found = true;