From d19be6639999970105820d690952fee5b8e874ec Mon Sep 17 00:00:00 2001 From: Christiaan Janssen Date: Wed, 1 Feb 2012 16:47:26 +0100 Subject: QmlProfiling: don't send v8 data if not profiling Change-Id: I41085ed06bcf28e9de0a72f25076b91b9a3b2aea Reviewed-by: Aurindam Jana Reviewed-by: Kai Koehne --- .../debugger/qv8profilerservice/tst_qv8profilerservice.cpp | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) (limited to 'tests') diff --git a/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp b/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp index 03d14062a8..c70d726fca 100644 --- a/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp +++ b/tests/auto/declarative/debugger/qv8profilerservice/tst_qv8profilerservice.cpp @@ -216,9 +216,14 @@ void tst_QV8ProfilerService::blockingConnectWithTraceDisabled() connect(true); QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); - m_client->startProfiling(""); m_client->stopProfiling(""); + if (QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()), 1000)) { + QString failMsg + = QString("Unexpected trace received! App output: %1\n\n").arg(m_process->output()); + QFAIL(qPrintable(failMsg)); + } m_client->startProfiling(""); + m_client->stopProfiling(""); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()))) { QString failMsg = QString("No trace received in time. App output: %1\n\n").arg(m_process->output()); @@ -231,8 +236,8 @@ void tst_QV8ProfilerService::nonBlockingConnect() connect(false); QTRY_COMPARE(m_client->status(), QDeclarativeDebugClient::Enabled); - m_client->stopProfiling(""); m_client->startProfiling(""); + m_client->stopProfiling(""); if (!QDeclarativeDebugTest::waitForSignal(m_client, SIGNAL(complete()))) { QString failMsg = QString("No trace received in time. App output: %1\n\n").arg(m_process->output()); -- cgit v1.2.3