forked from qt-creator/qt-creator
Autotest: Use FilePath::searchInDirectories
FilePath::searchInDirectories handles absolute paths on devices better unlike Environment::searchInPath() which requires a QString argument. Previously the device:// part was dropped when trying to run remote tests. Fixes: QTCREATORBUG-29183 Change-Id: Idd04cdb8798d04abf88ab6cb4b68eb73d890a482 Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Christian Stenger <christian.stenger@qt.io>
This commit is contained in:
@@ -57,9 +57,10 @@ FilePath ITestConfiguration::executableFilePath() const
|
||||
if (!hasExecutable())
|
||||
return {};
|
||||
|
||||
const Environment env = m_runnable.environment.hasChanges()
|
||||
? m_runnable.environment : Environment::systemEnvironment();
|
||||
return env.searchInPath(m_runnable.command.executable().path());
|
||||
const Environment env = m_runnable.environment.appliedToEnvironment(
|
||||
m_runnable.command.executable().deviceEnvironment());
|
||||
|
||||
return m_runnable.command.executable().searchInDirectories(env.path());
|
||||
}
|
||||
|
||||
Environment ITestConfiguration::filteredEnvironment(const Environment &original) const
|
||||
|
||||
Reference in New Issue
Block a user