diff options
author | Brad King <brad.king@kitware.com> | 2013-10-22 13:08:15 (GMT) |
---|---|---|
committer | CMake Topic Stage <kwrobot@kitware.com> | 2013-10-22 13:08:15 (GMT) |
commit | 7809adb8145ce0d1831dc34c49f1406ad7fa68ad (patch) | |
tree | 22a1b7cd6e577749e35aa0028860dfcecbb0f243 /Tests/RunCMake/string/Concat.cmake | |
parent | c9518497997845306b2d1127fbd7acf4e6081fe8 (diff) | |
parent | 4e184a21beda9de3703ecda94085c234f5bbd7da (diff) | |
download | CMake-7809adb8145ce0d1831dc34c49f1406ad7fa68ad.zip CMake-7809adb8145ce0d1831dc34c49f1406ad7fa68ad.tar.gz CMake-7809adb8145ce0d1831dc34c49f1406ad7fa68ad.tar.bz2 |
Merge topic 'string-CONCAT-command'
4e184a2 string: Add CONCAT sub-command
Diffstat (limited to 'Tests/RunCMake/string/Concat.cmake')
-rw-r--r-- | Tests/RunCMake/string/Concat.cmake | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/Tests/RunCMake/string/Concat.cmake b/Tests/RunCMake/string/Concat.cmake new file mode 100644 index 0000000..7260c95 --- /dev/null +++ b/Tests/RunCMake/string/Concat.cmake @@ -0,0 +1,19 @@ +set(b b) +set(out x) +string(CONCAT out) +if(NOT out STREQUAL "") + message(FATAL_ERROR "\"string(CONCAT out)\" set out to \"${out}\"") +endif() +string(CONCAT out a) +if(NOT out STREQUAL "a") + message(FATAL_ERROR "\"string(CONCAT out a)\" set out to \"${out}\"") +endif() +string(CONCAT out a "b") +if(NOT out STREQUAL "ab") + message(FATAL_ERROR "\"string(CONCAT out a \"b\")\" set out to \"${out}\"") +endif() +string(CONCAT out a "${b}" [[ +${c}]]) +if(NOT out STREQUAL "ab\${c}") + message(FATAL_ERROR "\"string(CONCAT out a \"\${b}\" [[\${c}]])\" set out to \"${out}\"") +endif() |