Plugin Tests: Make 'all' override previous args, and give sensible order

If you write "all" it should mean "all", and "load" order makes more
sense than "alphabetic".

Change-Id: If90b665d714efaf0919ad418fbbe02c50a0fced2
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: Nikolai Kosjar <nikolai.kosjar@qt.io>
This commit is contained in:
Eike Ziller
2016-06-22 13:03:00 +02:00
parent 4cc69911e9
commit 5838874b1d

View File

@@ -112,10 +112,10 @@ bool OptionsParser::checkForTestOptions()
if (m_currentArg == QLatin1String(TEST_OPTION)) {
if (nextToken(RequiredToken)) {
if (m_currentArg == QLatin1String("all")) {
foreach (PluginSpec *spec, m_pmPrivate->pluginSpecs) {
if (spec && !m_pmPrivate->containsTestSpec(spec))
m_pmPrivate->testSpecs.append(PluginManagerPrivate::TestSpec(spec));
}
m_pmPrivate->testSpecs =
Utils::transform(m_pmPrivate->loadQueue(), [](PluginSpec *spec) {
return PluginManagerPrivate::TestSpec(spec);
});
} else {
QStringList args = m_currentArg.split(QLatin1Char(','));
const QString pluginName = args.takeFirst();