Format attempted test file/dir lookups more nicely in the error case

This commit is contained in:
Martchus 2021-04-06 17:46:15 +02:00
parent f30947cc75
commit 0fb533ffc5
1 changed files with 4 additions and 4 deletions

View File

@ -241,8 +241,8 @@ std::string TestApplication::testFilePath(const std::string &relativeTestFilePat
return path;
}
}
throw std::runtime_error("The test file \"" % relativeTestFilePath % "\" can not be located. Was looking under:"
+ joinStrings(m_testFilesPaths, "\n", false, std::string(), relativeTestFilePath));
throw std::runtime_error("The test file \"" % relativeTestFilePath % "\" can not be located. Was looking under:\n"
+ joinStrings(m_testFilesPaths, "\n", false, " - ", relativeTestFilePath));
}
/*!
@ -259,8 +259,8 @@ std::string TestApplication::testDirPath(const std::string &relativeTestDirPath)
return path;
}
}
throw std::runtime_error("The test directory \"" % relativeTestDirPath % "\" can not be located. Was looking under:"
+ joinStrings(m_testFilesPaths, "\n", false, std::string(), relativeTestDirPath));
throw std::runtime_error("The test directory \"" % relativeTestDirPath % "\" can not be located. Was looking under:\n"
+ joinStrings(m_testFilesPaths, "\n", false, " - ", relativeTestDirPath));
}
/*!