Skip to content
Snippets Groups Projects
Commit 1c40c80a authored by Benedikt Conze's avatar Benedikt Conze
Browse files

Smarter integration test file path identification

parent f4a310de
Branches
Tags
1 merge request!45Merge branch 'release/v1.2.0' into 'master'
......@@ -290,8 +290,15 @@ TEST_P(IntegrationFixture, myNameIntegrationTest) {
", bonus points: " + std::to_string(useBonus));
// Open the exam with the given files
const auto rootPath = std::filesystem::path(TESTING_RWTHONLINE_DIRECTORY) /
"../../integration_test";
std::string file{__FILE__};
std::filesystem::path rootPath{};
if (file.find('/') != std::string::npos) {
rootPath = std::filesystem::path({file.substr(0, file.rfind('/'))});
} else {
rootPath = std::filesystem::path({file.substr(0, file.rfind('\\'))});
}
std::cout << "Root path: " << rootPath.string() << std::endl;
const auto dynexitePath =
rootPath / "dynexite" / (dynexiteFileName.toStdString() + ".csv");
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment