mirror of
https://github.com/OpenMW/openmw.git
synced 2025-03-03 12:09:39 +00:00
added quotes and introduced test to cover space in directory for config files
This commit is contained in:
parent
df06e0d7b9
commit
61fb575757
1 changed files with 3 additions and 3 deletions
|
@ -42,11 +42,11 @@ int runBinary(
|
||||||
{
|
{
|
||||||
#ifdef _WIN32
|
#ifdef _WIN32
|
||||||
std::wstringstream cmd;
|
std::wstringstream cmd;
|
||||||
cmd << binaryPath.native() << L" -i " << iniPath.native() << L" -c " << cfgPath.native();
|
cmd << binaryPath.native() << L" -i " << '"' << iniPath.native() << '"' << L" -c " << '"' << cfgPath.native() << '"';
|
||||||
return _wsystem(cmd.str().c_str());
|
return _wsystem(cmd.str().c_str());
|
||||||
#else
|
#else
|
||||||
std::stringstream cmd;
|
std::stringstream cmd;
|
||||||
cmd << binaryPath << " -i " << iniPath << " -c " << cfgPath;
|
cmd << binaryPath << " -i " << "'" << iniPath << "'" << " -c " << "'" << cfgPath << "'";
|
||||||
return std::system(cmd.str().c_str());
|
return std::system(cmd.str().c_str());
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
@ -57,7 +57,7 @@ struct TestParam
|
||||||
std::string fileName;
|
std::string fileName;
|
||||||
};
|
};
|
||||||
|
|
||||||
const std::vector<TestParam> testParams = { { "ascii", "ascii" }, { "unicode", "(╯°□°)╯︵ ┻━┻" }, { "emoji", "💩" } };
|
const std::vector<TestParam> testParams = { { "ascii", "ascii" }, { "space", "spaaaaa ce" }, { "unicode", "(╯°□°)╯︵ ┻━┻" }, { "emoji", "💩" } };
|
||||||
|
|
||||||
class IniImporterTest : public ::testing::TestWithParam<TestParam>
|
class IniImporterTest : public ::testing::TestWithParam<TestParam>
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue