summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CPack
diff options
context:
space:
mode:
authorDomen Vrankar <domen.vrankar@gmail.com>2017-10-31 11:19:10 (GMT)
committerDomen Vrankar <domen.vrankar@gmail.com>2017-11-08 19:27:11 (GMT)
commita4c829167dc8fa24e151d2afde7896b4588b24ad (patch)
tree498c774a7ea451f955c635d84a3e42723c1664c1 /Tests/RunCMake/CPack
parent670ad047b34d983daf1f17f8b32c4abe2b7f22b1 (diff)
downloadCMake-a4c829167dc8fa24e151d2afde7896b4588b24ad.zip
CMake-a4c829167dc8fa24e151d2afde7896b4588b24ad.tar.gz
CMake-a4c829167dc8fa24e151d2afde7896b4588b24ad.tar.bz2
CPack test: expand output checking fallback
Some tests can have the same output for a certain subtest no matter which packaging generator is used.
Diffstat (limited to 'Tests/RunCMake/CPack')
-rw-r--r--Tests/RunCMake/CPack/CPackTestHelpers.cmake2
-rw-r--r--Tests/RunCMake/CPack/README.txt1
2 files changed, 3 insertions, 0 deletions
diff --git a/Tests/RunCMake/CPack/CPackTestHelpers.cmake b/Tests/RunCMake/CPack/CPackTestHelpers.cmake
index f883c69..5337b2c 100644
--- a/Tests/RunCMake/CPack/CPackTestHelpers.cmake
+++ b/Tests/RunCMake/CPack/CPackTestHelpers.cmake
@@ -68,6 +68,8 @@ function(run_cpack_test_common_ TEST_NAME types build SUBTEST_SUFFIX source PACK
set(RunCMake-std${o}-file "tests/${TEST_NAME}/${TEST_TYPE}-${SUBTEST_SUFFIX}-std${o}.txt")
elseif(EXISTS ${RunCMake_SOURCE_DIR}/tests/${TEST_NAME}/${TEST_TYPE}-std${o}.txt)
set(RunCMake-std${o}-file "tests/${TEST_NAME}/${TEST_TYPE}-std${o}.txt")
+ elseif(SUBTEST_SUFFIX AND EXISTS ${RunCMake_SOURCE_DIR}/tests/${TEST_NAME}/${SUBTEST_SUFFIX}-std${o}.txt)
+ set(RunCMake-std${o}-file "tests/${TEST_NAME}/${SUBTEST_SUFFIX}-std${o}.txt")
elseif(EXISTS ${RunCMake_SOURCE_DIR}/${TEST_TYPE}/default_expected_std${o}.txt)
set(RunCMake-std${o}-file "${TEST_TYPE}/default_expected_std${o}.txt")
endif()
diff --git a/Tests/RunCMake/CPack/README.txt b/Tests/RunCMake/CPack/README.txt
index 5a95927..5877f97 100644
--- a/Tests/RunCMake/CPack/README.txt
+++ b/Tests/RunCMake/CPack/README.txt
@@ -167,6 +167,7 @@ NOTE: For subtests generator name can also be suffixed with subtest name and/or
- generator name + packaging type
- generator name + subtest name
- generator name
+ - subtest name
- default generator
File name format: '<generator_name>-<packaging_type>-<subtest_name>-std<type>.txt'
where <type> can either be 'out' or 'err'.