summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CMakeLists.txt
diff options
context:
space:
mode:
authorKyle Edwards <kyle.edwards@kitware.com>2018-12-13 22:57:09 (GMT)
committerKyle Edwards <kyle.edwards@kitware.com>2019-01-10 18:56:35 (GMT)
commit450131cc0e80f22f169f2647dc7ecb1bd1024cf6 (patch)
tree7ef5c77d6e81c74d1b361e1701e5ec28f69c7333 /Tests/RunCMake/CMakeLists.txt
parent6092a770f66bff959749170141d44188f4b6f3f1 (diff)
downloadCMake-450131cc0e80f22f169f2647dc7ecb1bd1024cf6.zip
CMake-450131cc0e80f22f169f2647dc7ecb1bd1024cf6.tar.gz
CMake-450131cc0e80f22f169f2647dc7ecb1bd1024cf6.tar.bz2
Tests: Add infrastructure to split up large CPack tests
This allows CPack generator tests to be split into smaller tests of the format "<generator>.<test>".
Diffstat (limited to 'Tests/RunCMake/CMakeLists.txt')
-rw-r--r--Tests/RunCMake/CMakeLists.txt7
1 files changed, 6 insertions, 1 deletions
diff --git a/Tests/RunCMake/CMakeLists.txt b/Tests/RunCMake/CMakeLists.txt
index e222376..63c5374 100644
--- a/Tests/RunCMake/CMakeLists.txt
+++ b/Tests/RunCMake/CMakeLists.txt
@@ -42,7 +42,12 @@ function(add_RunCMake_test_group test types)
# much system information so it is easier to set programs and environment
# values here
unset(${test}_${type}_FOUND_PREREQUIREMENTS)
- include("${CMAKE_CURRENT_SOURCE_DIR}/${test}/${type}/Prerequirements.cmake")
+ if(EXISTS "${CMAKE_CURRENT_SOURCE_DIR}/${test}/${type}/Prerequirements.cmake")
+ include("${CMAKE_CURRENT_SOURCE_DIR}/${test}/${type}/Prerequirements.cmake")
+ else()
+ string(REGEX MATCH "^[^.]*" main_type "${type}")
+ include("${CMAKE_CURRENT_SOURCE_DIR}/${test}/${main_type}/Prerequirements.cmake")
+ endif()
get_test_prerequirements("${test}_${type}_FOUND_PREREQUIREMENTS"
"${TEST_CONFIG_DIR}/${type}_config.cmake")