diff options
author | Brad King <brad.king@kitware.com> | 2019-01-31 16:15:34 +0000 |
---|---|---|
committer | Kitware Robot <kwrobot@kitware.com> | 2019-01-31 11:16:53 -0500 |
commit | ca0310b919cb389618d480cbdc0124609051866a (patch) | |
tree | bbc39c790611ea7fe05060fa594c59bbc2a0c589 /Tests | |
parent | a2dc420cd4946eb3b17fcdcc6c32dafc7c679ad5 (diff) | |
parent | 198650ae7399cc086c49e58b0a9e03e9efb86235 (diff) | |
download | cmake-ca0310b919cb389618d480cbdc0124609051866a.tar.gz |
Merge topic 'set-validate-cache-type'
198650ae73 set: warn if CACHE type is not recognized
Acked-by: Kitware Robot <kwrobot@kitware.com>
Merge-request: !2874
Diffstat (limited to 'Tests')
-rw-r--r-- | Tests/RunCMake/set/RunCMakeTest.cmake | 1 | ||||
-rw-r--r-- | Tests/RunCMake/set/UnknownCacheType-stderr.txt | 5 | ||||
-rw-r--r-- | Tests/RunCMake/set/UnknownCacheType.cmake | 1 |
3 files changed, 7 insertions, 0 deletions
diff --git a/Tests/RunCMake/set/RunCMakeTest.cmake b/Tests/RunCMake/set/RunCMakeTest.cmake index b8e8cf1f9c..ea63d0bdc4 100644 --- a/Tests/RunCMake/set/RunCMakeTest.cmake +++ b/Tests/RunCMake/set/RunCMakeTest.cmake @@ -3,3 +3,4 @@ include(RunCMake) run_cmake(ParentScope) run_cmake(ParentPulling) run_cmake(ParentPullingRecursive) +run_cmake(UnknownCacheType) diff --git a/Tests/RunCMake/set/UnknownCacheType-stderr.txt b/Tests/RunCMake/set/UnknownCacheType-stderr.txt new file mode 100644 index 0000000000..6e1c8114a7 --- /dev/null +++ b/Tests/RunCMake/set/UnknownCacheType-stderr.txt @@ -0,0 +1,5 @@ +CMake Warning \(dev\) at UnknownCacheType.cmake:1 \(set\): + implicitly converting 'unknown_type_sample' to 'STRING' type. +Call Stack \(most recent call first\): + CMakeLists.txt:3 \(include\) +This warning is for project developers. Use -Wno-dev to suppress it. diff --git a/Tests/RunCMake/set/UnknownCacheType.cmake b/Tests/RunCMake/set/UnknownCacheType.cmake new file mode 100644 index 0000000000..f2b5d051d2 --- /dev/null +++ b/Tests/RunCMake/set/UnknownCacheType.cmake @@ -0,0 +1 @@ +set (sample_key sample_value CACHE unknown_type_sample "sample doc") |