diff options
Diffstat (limited to 'tests/auto/qml/debugger/qqmlenginedebugservice/tst_qqmlenginedebugservice.cpp')
-rw-r--r-- | tests/auto/qml/debugger/qqmlenginedebugservice/tst_qqmlenginedebugservice.cpp | 67 |
1 files changed, 34 insertions, 33 deletions
diff --git a/tests/auto/qml/debugger/qqmlenginedebugservice/tst_qqmlenginedebugservice.cpp b/tests/auto/qml/debugger/qqmlenginedebugservice/tst_qqmlenginedebugservice.cpp index bc3220ad8c..4568d25dc1 100644 --- a/tests/auto/qml/debugger/qqmlenginedebugservice/tst_qqmlenginedebugservice.cpp +++ b/tests/auto/qml/debugger/qqmlenginedebugservice/tst_qqmlenginedebugservice.cpp @@ -1,60 +1,57 @@ /**************************************************************************** ** -** Copyright (C) 2015 The Qt Company Ltd. -** Contact: http://www.qt.io/licensing/ +** Copyright (C) 2016 The Qt Company Ltd. +** Contact: https://www.qt.io/licensing/ ** ** This file is part of the test suite of the Qt Toolkit. ** -** $QT_BEGIN_LICENSE:LGPL21$ +** $QT_BEGIN_LICENSE:GPL-EXCEPT$ ** Commercial License Usage ** Licensees holding valid commercial Qt licenses may use this file in ** accordance with the commercial license agreement provided with the ** Software or, alternatively, in accordance with the terms contained in ** a written agreement between you and The Qt Company. For licensing terms -** and conditions see http://www.qt.io/terms-conditions. For further -** information use the contact form at http://www.qt.io/contact-us. +** and conditions see https://www.qt.io/terms-conditions. For further +** information use the contact form at https://www.qt.io/contact-us. ** -** GNU Lesser General Public License Usage -** Alternatively, this file may be used under the terms of the GNU Lesser -** General Public License version 2.1 or version 3 as published by the Free -** Software Foundation and appearing in the file LICENSE.LGPLv21 and -** LICENSE.LGPLv3 included in the packaging of this file. Please review the -** following information to ensure the GNU Lesser General Public License -** requirements will be met: https://www.gnu.org/licenses/lgpl.html and -** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. -** -** As a special exception, The Qt Company gives you certain additional -** rights. These rights are described in The Qt Company LGPL Exception -** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** GNU General Public License Usage +** Alternatively, this file may be used under the terms of the GNU +** General Public License version 3 as published by the Free Software +** Foundation with exceptions as appearing in the file LICENSE.GPL3-EXCEPT +** included in the packaging of this file. Please review the following +** information to ensure the GNU General Public License requirements will +** be met: https://www.gnu.org/licenses/gpl-3.0.html. ** ** $QT_END_LICENSE$ ** ****************************************************************************/ -#include <qtest.h> -#include <QSignalSpy> -#include <QTimer> -#include <QHostAddress> -#include <QDebug> -#include <QThread> -#include <QModelIndex> -#include <QtQml/qqmlengine.h> -#include <QtQml/qqmlcontext.h> -#include <QtQml/qqmlcomponent.h> -#include <QtQml/qqmlexpression.h> -#include <QtQml/qqmlproperty.h> -#include <QtQuick/qquickitem.h> +#include "qqmlenginedebugclient.h" +#include "debugutil_p.h" +#include "../../../shared/util.h" #include <private/qqmlbinding_p.h> #include <private/qqmlboundsignal_p.h> #include <private/qqmldebugservice_p.h> #include <private/qqmlmetatype_p.h> #include <private/qqmlproperty_p.h> +#include <private/qqmldebugconnection_p.h> -#include "debugutil_p.h" -#include "qqmlenginedebugclient.h" +#include <QtTest/qtest.h> +#include <QtTest/qsignalspy.h> -#include "../../../shared/util.h" +#include <QtQml/qqmlengine.h> +#include <QtQml/qqmlcontext.h> +#include <QtQml/qqmlcomponent.h> +#include <QtQml/qqmlexpression.h> +#include <QtQml/qqmlproperty.h> +#include <QtQuick/qquickitem.h> + +#include <QtNetwork/qhostaddress.h> +#include <QtCore/qtimer.h> +#include <QtCore/qdebug.h> +#include <QtCore/qthread.h> +#include <QtCore/qabstractitemmodel.h> #define QVERIFYOBJECT(statement) \ do {\ @@ -352,7 +349,11 @@ void tst_QQmlEngineDebugService::initTestCase() bool ok = m_conn->waitForConnected(); QVERIFY(ok); m_dbg = new QQmlEngineDebugClient(m_conn); + QList<QQmlDebugClient *> others = QQmlDebugTest::createOtherClients(m_conn); QTRY_COMPARE(m_dbg->state(), QQmlEngineDebugClient::Enabled); + foreach (QQmlDebugClient *other, others) + QCOMPARE(other->state(), QQmlDebugClient::Unavailable); + qDeleteAll(others); } void tst_QQmlEngineDebugService::cleanupTestCase() |