From 9107592550dcdcd549814b72a4d5f3c1c2616097 Mon Sep 17 00:00:00 2001 From: Andy Cedilnik Date: Sun, 8 Feb 2004 13:23:48 -0500 Subject: [PATCH] ENH: Attempt to support tests in funky subdirectories --- Source/cmCTest.cxx | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/Source/cmCTest.cxx b/Source/cmCTest.cxx index eb14f649d..fe2835a1c 100644 --- a/Source/cmCTest.cxx +++ b/Source/cmCTest.cxx @@ -4344,6 +4344,18 @@ int cmCTest::RunCMakeAndTest(std::string* outstring) else { failed.push_back(tryPath); + std::string filepath = cmSystemTools::GetFilenamePath(m_TestCommand); + std::string filename = cmSystemTools::GetFilenameName(m_TestCommand); + tryPath = filepath + "/" + m_ConfigType + "/" + filepath; + if ( cmSystemTools::FileExists(tryPath.c_str()) && + !cmSystemTools::FileIsDirectory(tryPath.c_str()) ) + { + fullPath = cmSystemTools::CollapseFullPath(tryPath.c_str()); + } + else + { + failed.push_back(tryPath); + } } } }