diff options
Diffstat (limited to 'tests/auto/qlocalsocket')
-rw-r--r-- | tests/auto/qlocalsocket/tst_qlocalsocket.cpp | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/tests/auto/qlocalsocket/tst_qlocalsocket.cpp b/tests/auto/qlocalsocket/tst_qlocalsocket.cpp index 5d73c98..b272716 100644 --- a/tests/auto/qlocalsocket/tst_qlocalsocket.cpp +++ b/tests/auto/qlocalsocket/tst_qlocalsocket.cpp @@ -492,11 +492,11 @@ void tst_QLocalSocket::sendData() // test creating a connection socket.connectToServer(name); bool timedOut = true; + QCOMPARE(server.waitForNewConnection(3000, &timedOut), canListen); -#if defined(QT_LOCALSOCKET_TCP) + +#if defined(QT_LOCALSOCKET_TCP) || defined(Q_OS_SYMBIAN) QTest::qWait(250); -#elif defined(Q_OS_SYMBIAN) - QTest::qWait(10000); #endif QVERIFY(!timedOut); QCOMPARE(spyConnected.count(), canListen ? 1 : 0); @@ -530,7 +530,9 @@ void tst_QLocalSocket::sendData() QCOMPARE(spyReadyRead.count(), 1); QVERIFY(testLine.startsWith(in.readLine())); + QVERIFY(wrote || serverSocket->waitForBytesWritten(1000)); + QCOMPARE(serverSocket->errorString(), QString("Unknown error")); QCOMPARE(socket.errorString(), QString("Unknown error")); } |