Fix paths to subprocesses when test is run from other directory

Now it's possible to run the test outside of directory
where the test is located.

Change-Id: I2a2c693d382917ac7b84488c8ccf161538b58238
Reviewed-by: hjk <hjk@qt.io>
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Jarek Kobus
2022-03-10 10:18:35 +01:00
parent a49c029056
commit b2331dd5f6

View File

@@ -105,7 +105,8 @@ static CommandLine subCommandLine()
{
QStringList args = QCoreApplication::arguments();
const QString binary = args.takeFirst();
return CommandLine(FilePath::fromString(binary), args);
const FilePath filePath = FilePath::fromString(QDir::currentPath()).resolvePath(binary);
return CommandLine(filePath, args);
}
class SubCreatorConfig