diff options
author | Kai Koehne <kai.koehne@nokia.com> | 2010-09-30 13:26:05 (GMT) |
---|---|---|
committer | Kai Koehne <kai.koehne@nokia.com> | 2010-09-30 13:35:42 (GMT) |
commit | a1f050fe4217d3a642ab7f4df8e50c21aa51689c (patch) | |
tree | dbade527ab520a29637317190125e108ebb0d57e /tests/auto/declarative/qdeclarativedebugclient | |
parent | db0c012d3eb5c5e30b0a932c5301cc03d43ba2ce (diff) | |
download | Qt-a1f050fe4217d3a642ab7f4df8e50c21aa51689c.zip Qt-a1f050fe4217d3a642ab7f4df8e50c21aa51689c.tar.gz Qt-a1f050fe4217d3a642ab7f4df8e50c21aa51689c.tar.bz2 |
QDeclarativeDebugClient: Make sure status is consistent
When statusChanged() is called during handsake state() was not the same
as the argument passed. Fix this by setting gotHello = true _before_
notifying the clients.
Reviewed-by: Christiaan Janssen
Task-number: QTBUG-14087
Diffstat (limited to 'tests/auto/declarative/qdeclarativedebugclient')
-rw-r--r-- | tests/auto/declarative/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/auto/declarative/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp b/tests/auto/declarative/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp index 72af3eb..a5f9846 100644 --- a/tests/auto/declarative/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp +++ b/tests/auto/declarative/qdeclarativedebugclient/tst_qdeclarativedebugclient.cpp @@ -77,6 +77,10 @@ void tst_QDeclarativeDebugClient::initTestCase() new QDeclarativeEngine(this); m_conn = new QDeclarativeDebugConnection(this); + + QDeclarativeDebugTestClient client("tst_QDeclarativeDebugClient::handshake()", m_conn); + QDeclarativeDebugTestService service("tst_QDeclarativeDebugClient::handshake()"); + m_conn->connectToHost("127.0.0.1", 3770); QTest::ignoreMessage(QtWarningMsg, "QDeclarativeDebugServer: Connection established"); @@ -84,6 +88,7 @@ void tst_QDeclarativeDebugClient::initTestCase() Q_ASSERT(ok); QTRY_VERIFY(QDeclarativeDebugService::hasDebuggingClient()); + QTRY_COMPARE(client.status(), QDeclarativeDebugClient::Enabled); } void tst_QDeclarativeDebugClient::name() |