The connectToHost() call can try to establish the connection directly
(synchronously), in which case the warning message will be output
before the subsequent ignoreMessage() call, causing the test to fail.
Change-Id: I08a6a7d4d090cbb942c348e0787b586c71318f99
Reviewed-by: Aurindam Jana <aurindam.jana@nokia.com>
{
QDeclarativeDebugConnection connection2;
- connection2.connectToHost("127.0.0.1", PORT);
QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugServer: Another client is already connected");
// will connect & immediately disconnect
+ connection2.connectToHost("127.0.0.1", PORT);
QVERIFY(connection2.waitForConnected());
QTRY_COMPARE(connection2.state(), QAbstractSocket::UnconnectedState);
QVERIFY(m_conn->isConnected());