Skip to content
Snippets Groups Projects
Commit 80803d18 authored by Jonathan Guinet's avatar Jonathan Guinet
Browse files

BUG: test extansion for multibaseline files. Mantis ref #476.

parent cbf46e50
No related branches found
No related tags found
No related merge requests found
......@@ -1013,9 +1013,10 @@ std::map<std::string, int> TestHelper::RegressionTestBaselines(char *baselineFil
std::string originalBaseline(baselineFilename);
int x = 0;
std::string::size_type suffixPos = originalBaseline.rfind(".");
std::string::size_type suffixPos = originalBaseline.find_last_of(".");
std::string::size_type maxPathPos = originalBaseline.find_last_of("/");
std::string suffix;
if (suffixPos != std::string::npos)
if ((suffixPos != std::string::npos) && ((suffixPos>maxPathPos) || (maxPathPos==std::string::npos)))
{
suffix = originalBaseline.substr(suffixPos, originalBaseline.length());
originalBaseline.erase(suffixPos, originalBaseline.length());
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment