aboutsummaryrefslogtreecommitdiffstats
path: root/tests/auto/qml/debugger/qqmldebugjs
diff options
context:
space:
mode:
authorAurindam Jana <aurindam.jana@digia.com>2013-03-18 17:17:52 +0100
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-04-02 13:26:03 +0200
commitf15595901b645fc3c168ef18f81ae4617b439e92 (patch)
treeedcb11ea4a7ee984a0e66b1b1f94fbdf1b08dd2f /tests/auto/qml/debugger/qqmldebugjs
parent3e0bcbff98346385ec32bc951cd958d1c1bfb371 (diff)
Debugger: Accepts port range as arguments
Allow a port range to pass on command line, and try to listen on any of the ports in the range. (Re)using the ',' separator allows for backwards compatibility, that is, also Qt 4 will accept a -qmljsdebugger=port:1000,1010 argument, but will only try to listen on port 1000. Change-Id: Ic03fe20e4aee9ecdea86651f46f1df5cb19bd75c Reviewed-by: Kai Koehne <kai.koehne@digia.com>
Diffstat (limited to 'tests/auto/qml/debugger/qqmldebugjs')
-rw-r--r--tests/auto/qml/debugger/qqmldebugjs/tst_qqmldebugjs.cpp7
1 files changed, 4 insertions, 3 deletions
diff --git a/tests/auto/qml/debugger/qqmldebugjs/tst_qqmldebugjs.cpp b/tests/auto/qml/debugger/qqmldebugjs/tst_qqmldebugjs.cpp
index 3d5d4d5243..9c2ba5bcde 100644
--- a/tests/auto/qml/debugger/qqmldebugjs/tst_qqmldebugjs.cpp
+++ b/tests/auto/qml/debugger/qqmldebugjs/tst_qqmldebugjs.cpp
@@ -124,8 +124,8 @@ const char *UNCAUGHT = "uncaught";
//const char *PAUSE = "pause";
//const char *RESUME = "resume";
-const char *BLOCKMODE = "-qmljsdebugger=port:3771,block";
-const char *NORMALMODE = "-qmljsdebugger=port:3771";
+const char *BLOCKMODE = "-qmljsdebugger=port:3771,3800,block";
+const char *NORMALMODE = "-qmljsdebugger=port:3771,3800";
const char *TEST_QMLFILE = "test.qml";
const char *TEST_JSFILE = "test.js";
const char *TIMER_QMLFILE = "timer.qml";
@@ -1015,7 +1015,8 @@ bool tst_QQmlDebugJS::init(const QString &qmlFile, bool blockMode)
return false;
}
- connection->connectToHost("127.0.0.1", 3771);
+ const int port = process->debugPort();
+ connection->connectToHost("127.0.0.1", port);
if (!connection->waitForConnected()) {
qDebug() << "could not connect to host!";
return false;