diff options
author | Ulf Hermann <ulf.hermann@qt.io> | 2018-04-16 13:42:43 +0200 |
---|---|---|
committer | Ulf Hermann <ulf.hermann@qt.io> | 2018-04-16 13:08:45 +0000 |
commit | 17d530d60db270e3c011296a4f2ddc444a2acdff (patch) | |
tree | 1b13e2c3a610780ecab022f0d4a43500d0adcc8f /src/plugins/qmlprofiler/tests | |
parent | fa11070977ea65e2e1d3a94e5c8c980494388294 (diff) | |
download | qt-creator-17d530d60db270e3c011296a4f2ddc444a2acdff.tar.gz |
Make sure we always quote the qmldebug command line arguments
Change-Id: I5ce68c238e0ab05d19715659a9cc2161e51e1a7e
Task-number: QTCREATORBUG-20260
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/plugins/qmlprofiler/tests')
-rw-r--r-- | src/plugins/qmlprofiler/tests/localqmlprofilerrunner_test.cpp | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/src/plugins/qmlprofiler/tests/localqmlprofilerrunner_test.cpp b/src/plugins/qmlprofiler/tests/localqmlprofilerrunner_test.cpp index 007dac486a..1f2dcce4b2 100644 --- a/src/plugins/qmlprofiler/tests/localqmlprofilerrunner_test.cpp +++ b/src/plugins/qmlprofiler/tests/localqmlprofilerrunner_test.cpp @@ -31,6 +31,7 @@ #include <qmlprofiler/qmlprofilertool.h> #include <utils/url.h> +#include <utils/temporaryfile.h> #include <QtTest> #include <QTcpServer> @@ -148,6 +149,31 @@ void LocalQmlProfilerRunnerTest::testRunner() runControl->initiateFinish(); QTRY_VERIFY(runControl.isNull()); QVERIFY(profiler.isNull()); + + debuggee.commandLineArguments = QString("-test QmlProfiler,"); + serverUrl.setScheme(Utils::urlSocketScheme()); + { + Utils::TemporaryFile file("file with spaces"); + if (file.open()) + serverUrl.setPath(file.fileName()); + } + + runControl = new ProjectExplorer::RunControl(nullptr, + ProjectExplorer::Constants::QML_PROFILER_RUN_MODE); + runControl->setRunnable(debuggee); + profiler = new LocalQmlProfilerSupport(&tool, runControl, serverUrl); + connectRunner(); + runControl->initiateStart(); + + QTRY_VERIFY_WITH_TIMEOUT(running, 30000); + QTRY_VERIFY_WITH_TIMEOUT(!running, 30000); + QCOMPARE(startCount, 4); + QCOMPARE(stopCount, 4); + QCOMPARE(runCount, 3); + + runControl->initiateFinish(); + QTRY_VERIFY(runControl.isNull()); + QVERIFY(profiler.isNull()); } void LocalQmlProfilerRunnerTest::testFindFreePort() |