aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/autotest
diff options
context:
space:
mode:
authorhjk <hjk@qt.io>2020-06-17 06:35:31 +0200
committerhjk <hjk@qt.io>2020-06-17 05:55:25 +0000
commit1c81a3b3e887d9774cc342caafccebd7cdb90f19 (patch)
tree7008ebd0f4d8de1299dfc5d734832175d7a4624f /src/plugins/autotest
parent6e798401a0558ad039fff62b80e97660053b60b8 (diff)
All: Use Utils::SkipEmptyParts
Task-number: QTCREATORBUG-24098 Change-Id: Iab45de9a9c17ddc39a0e343b1175d4f6cb94b098 Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'src/plugins/autotest')
-rw-r--r--src/plugins/autotest/boost/boosttestconfiguration.cpp4
-rw-r--r--src/plugins/autotest/catch/catchconfiguration.cpp4
-rw-r--r--src/plugins/autotest/gtest/gtestconfiguration.cpp3
-rw-r--r--src/plugins/autotest/gtest/gtesttreeitem.cpp8
-rw-r--r--src/plugins/autotest/qtest/qttestconfiguration.cpp4
-rw-r--r--src/plugins/autotest/quick/quicktestconfiguration.cpp4
6 files changed, 19 insertions, 8 deletions
diff --git a/src/plugins/autotest/boost/boosttestconfiguration.cpp b/src/plugins/autotest/boost/boosttestconfiguration.cpp
index e38243a89f..dfb0cb78a7 100644
--- a/src/plugins/autotest/boost/boosttestconfiguration.cpp
+++ b/src/plugins/autotest/boost/boosttestconfiguration.cpp
@@ -32,6 +32,8 @@
#include "../itestframework.h"
#include "../testsettings.h"
+#include <utils/stringutils.h>
+
namespace Autotest {
namespace Internal {
@@ -126,7 +128,7 @@ QStringList BoostTestConfiguration::argumentsForTestRunner(QStringList *omitted)
if (AutotestPlugin::settings()->processArgs) {
arguments << filterInterfering(runnable().commandLineArguments.split(
- ' ', QString::SkipEmptyParts), omitted);
+ ' ', Utils::SkipEmptyParts), omitted);
}
return arguments;
}
diff --git a/src/plugins/autotest/catch/catchconfiguration.cpp b/src/plugins/autotest/catch/catchconfiguration.cpp
index f314ef49bb..e9e957a143 100644
--- a/src/plugins/autotest/catch/catchconfiguration.cpp
+++ b/src/plugins/autotest/catch/catchconfiguration.cpp
@@ -30,6 +30,8 @@
#include "../itestframework.h"
#include "../testsettings.h"
+#include <utils/stringutils.h>
+
namespace Autotest {
namespace Internal {
@@ -99,7 +101,7 @@ QStringList CatchConfiguration::argumentsForTestRunner(QStringList *omitted) con
if (AutotestPlugin::settings()->processArgs) {
arguments << filterInterfering(runnable().commandLineArguments.split(
- ' ', QString::SkipEmptyParts), omitted);
+ ' ', Utils::SkipEmptyParts), omitted);
}
auto settings = dynamic_cast<CatchTestSettings *>(framework()->frameworkSettings());
diff --git a/src/plugins/autotest/gtest/gtestconfiguration.cpp b/src/plugins/autotest/gtest/gtestconfiguration.cpp
index 615ddcd3da..13cbebc246 100644
--- a/src/plugins/autotest/gtest/gtestconfiguration.cpp
+++ b/src/plugins/autotest/gtest/gtestconfiguration.cpp
@@ -32,6 +32,7 @@
#include "../testsettings.h"
#include <utils/algorithm.h>
+#include <utils/stringutils.h>
namespace Autotest {
namespace Internal {
@@ -76,7 +77,7 @@ QStringList GTestConfiguration::argumentsForTestRunner(QStringList *omitted) con
QStringList arguments;
if (AutotestPlugin::settings()->processArgs) {
arguments << filterInterfering(runnable().commandLineArguments.split(
- ' ', QString::SkipEmptyParts), omitted);
+ ' ', Utils::SkipEmptyParts), omitted);
}
const QStringList &testSets = testCases();
diff --git a/src/plugins/autotest/gtest/gtesttreeitem.cpp b/src/plugins/autotest/gtest/gtesttreeitem.cpp
index f2821ca1bf..8b5c9eafc7 100644
--- a/src/plugins/autotest/gtest/gtesttreeitem.cpp
+++ b/src/plugins/autotest/gtest/gtesttreeitem.cpp
@@ -32,9 +32,11 @@
#include <cpptools/cppmodelmanager.h>
#include <projectexplorer/session.h>
+
#include <utils/algorithm.h>
#include <utils/icon.h>
#include <utils/qtcassert.h>
+#include <utils/stringutils.h>
#include <utils/theme/theme.h>
#include <QRegularExpression>
@@ -91,10 +93,10 @@ static bool matchesFilter(const QString &filter, const QString &fullTestName)
QStringList negative;
int startOfNegative = filter.indexOf('-');
if (startOfNegative == -1) {
- positive.append(filter.split(':', QString::SkipEmptyParts));
+ positive.append(filter.split(':', Utils::SkipEmptyParts));
} else {
- positive.append(filter.left(startOfNegative).split(':', QString::SkipEmptyParts));
- negative.append(filter.mid(startOfNegative + 1).split(':', QString::SkipEmptyParts));
+ positive.append(filter.left(startOfNegative).split(':', Utils::SkipEmptyParts));
+ negative.append(filter.mid(startOfNegative + 1).split(':', Utils::SkipEmptyParts));
}
QString testName = fullTestName;
diff --git a/src/plugins/autotest/qtest/qttestconfiguration.cpp b/src/plugins/autotest/qtest/qttestconfiguration.cpp
index a3bc92c67c..30a707ebab 100644
--- a/src/plugins/autotest/qtest/qttestconfiguration.cpp
+++ b/src/plugins/autotest/qtest/qttestconfiguration.cpp
@@ -32,6 +32,8 @@
#include "../itestframework.h"
#include "../testsettings.h"
+#include <utils/stringutils.h>
+
namespace Autotest {
namespace Internal {
@@ -50,7 +52,7 @@ QStringList QtTestConfiguration::argumentsForTestRunner(QStringList *omitted) co
QStringList arguments;
if (AutotestPlugin::settings()->processArgs) {
arguments.append(QTestUtils::filterInterfering(
- runnable().commandLineArguments.split(' ', QString::SkipEmptyParts),
+ runnable().commandLineArguments.split(' ', Utils::SkipEmptyParts),
omitted, false));
}
auto qtSettings = dynamic_cast<QtTestSettings *>(framework()->frameworkSettings());
diff --git a/src/plugins/autotest/quick/quicktestconfiguration.cpp b/src/plugins/autotest/quick/quicktestconfiguration.cpp
index e61c4f12d8..22abcb5df5 100644
--- a/src/plugins/autotest/quick/quicktestconfiguration.cpp
+++ b/src/plugins/autotest/quick/quicktestconfiguration.cpp
@@ -32,6 +32,8 @@
#include "../itestframework.h"
#include "../testsettings.h"
+#include <utils/stringutils.h>
+
namespace Autotest {
namespace Internal {
@@ -57,7 +59,7 @@ QStringList QuickTestConfiguration::argumentsForTestRunner(QStringList *omitted)
QStringList arguments;
if (AutotestPlugin::settings()->processArgs) {
arguments.append(QTestUtils::filterInterfering
- (runnable().commandLineArguments.split(' ', QString::SkipEmptyParts),
+ (runnable().commandLineArguments.split(' ', Utils::SkipEmptyParts),
omitted, true));
}