summaryrefslogtreecommitdiffstats
path: root/tests/auto/declarative/shared/debugutil.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/auto/declarative/shared/debugutil.cpp')
-rw-r--r--tests/auto/declarative/shared/debugutil.cpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/tests/auto/declarative/shared/debugutil.cpp b/tests/auto/declarative/shared/debugutil.cpp
index 7008529..8f6fdef 100644
--- a/tests/auto/declarative/shared/debugutil.cpp
+++ b/tests/auto/declarative/shared/debugutil.cpp
@@ -88,8 +88,8 @@ void QmlDebugTestService::messageReceived(const QByteArray &ba)
void QmlDebugTestService::enabledChanged(bool e)
{
- emit enabledStateChanged();
enabled = e;
+ emit enabledStateChanged();
}
@@ -100,17 +100,18 @@ QmlDebugTestClient::QmlDebugTestClient(const QString &s, QmlDebugConnection *c)
QByteArray QmlDebugTestClient::waitForResponse()
{
- QSignalSpy spy(this, SIGNAL(serverMessage(QByteArray)));
+ lastMsg.clear();
QmlDebugTest::waitForSignal(this, SIGNAL(serverMessage(QByteArray)));
- if (spy.count() == 0) {
+ if (lastMsg.isEmpty()) {
qWarning() << "tst_QmlDebugClient: no response from server!";
return QByteArray();
}
- return spy.at(0).at(0).value<QByteArray>();
+ return lastMsg;
}
void QmlDebugTestClient::messageReceived(const QByteArray &ba)
{
+ lastMsg = ba;
emit serverMessage(ba);
}