forked from qt-creator/qt-creator
Utils: Rename ProjectExplorer::Runnable into Utils::ProcessRunData
Move it into Utils lib. Change-Id: I3b6c16d18439cabddf59afc03116f13c1970102c Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -13,7 +13,6 @@
|
||||
#include "testprojectsettings.h"
|
||||
#include "testresultspane.h"
|
||||
#include "testrunner.h"
|
||||
#include "testsettings.h"
|
||||
#include "testsettingspage.h"
|
||||
#include "testtreeitem.h"
|
||||
#include "testtreemodel.h"
|
||||
@@ -47,13 +46,14 @@
|
||||
#include <projectexplorer/projectexplorericons.h>
|
||||
#include <projectexplorer/projectmanager.h>
|
||||
#include <projectexplorer/projectpanelfactory.h>
|
||||
#include <projectexplorer/runcontrol.h>
|
||||
#include <projectexplorer/runconfiguration.h>
|
||||
#include <projectexplorer/target.h>
|
||||
|
||||
#include <texteditor/textdocument.h>
|
||||
#include <texteditor/texteditor.h>
|
||||
|
||||
#include <utils/algorithm.h>
|
||||
#include <utils/processinterface.h>
|
||||
#include <utils/textutils.h>
|
||||
#include <utils/utilsicons.h>
|
||||
|
||||
|
||||
@@ -214,7 +214,7 @@ void TestConfiguration::completeTestInformation(TestRunMode runMode)
|
||||
continue;
|
||||
}
|
||||
|
||||
const Runnable runnable = runConfig->runnable();
|
||||
const ProcessRunData runnable = runConfig->runnable();
|
||||
// not the best approach - but depending on the build system and whether the executables
|
||||
// are going to get installed or not we have to soften the condition...
|
||||
const FilePath currentExecutable = ensureExeEnding(runnable.command.executable());
|
||||
@@ -246,7 +246,7 @@ void TestConfiguration::completeTestInformation(TestRunMode runMode)
|
||||
// we failed to find a valid runconfiguration - but we've got the executable already
|
||||
if (auto rc = target->activeRunConfiguration()) {
|
||||
if (isLocal(target)) { // FIXME for now only Desktop support
|
||||
const Runnable runnable = rc->runnable();
|
||||
const ProcessRunData runnable = rc->runnable();
|
||||
m_runnable.environment = runnable.environment;
|
||||
m_deducedConfiguration = true;
|
||||
m_deducedFrom = rc->displayName();
|
||||
|
||||
@@ -6,13 +6,18 @@
|
||||
#include "autotestconstants.h"
|
||||
|
||||
#include <projectexplorer/project.h>
|
||||
#include <projectexplorer/runcontrol.h>
|
||||
#include <projectexplorer/runconfiguration.h>
|
||||
|
||||
#include <utils/environment.h>
|
||||
#include <utils/processinterface.h>
|
||||
|
||||
#include <QPointer>
|
||||
#include <QStringList>
|
||||
|
||||
namespace Utils { class Process; }
|
||||
namespace Utils {
|
||||
class Process;
|
||||
class ProcessRunData;
|
||||
}
|
||||
|
||||
namespace Autotest {
|
||||
namespace Internal {
|
||||
@@ -49,10 +54,10 @@ public:
|
||||
void setTestCaseCount(int count) { m_testCaseCount = count; }
|
||||
int testCaseCount() const { return m_testCaseCount; }
|
||||
ProjectExplorer::Project *project() const { return m_project.data(); }
|
||||
ProjectExplorer::Runnable runnable() const { return m_runnable; }
|
||||
Utils::ProcessRunData runnable() const { return m_runnable; }
|
||||
|
||||
protected:
|
||||
ProjectExplorer::Runnable m_runnable;
|
||||
Utils::ProcessRunData m_runnable;
|
||||
|
||||
private:
|
||||
ITestBase *m_testBase = nullptr;
|
||||
|
||||
@@ -38,9 +38,9 @@ public:
|
||||
m_testConfig = config;
|
||||
}
|
||||
|
||||
ProjectExplorer::Runnable runnable() const override
|
||||
Utils::ProcessRunData runnable() const override
|
||||
{
|
||||
ProjectExplorer::Runnable r;
|
||||
Utils::ProcessRunData r;
|
||||
QTC_ASSERT(m_testConfig, return r);
|
||||
r.command.setExecutable(m_testConfig->executableFilePath());
|
||||
r.command.addArgs(m_testConfig->argumentsForTestRunner().join(' '), Utils::CommandLine::Raw);
|
||||
|
||||
@@ -539,7 +539,7 @@ void TestRunner::debugTests()
|
||||
runControl->copyDataFromRunConfiguration(config->runConfiguration());
|
||||
|
||||
QStringList omitted;
|
||||
Runnable inferior = config->runnable();
|
||||
ProcessRunData inferior = config->runnable();
|
||||
inferior.command.setExecutable(commandFilePath);
|
||||
|
||||
const QStringList args = config->argumentsForTestRunner(&omitted);
|
||||
|
||||
Reference in New Issue
Block a user