diff options
Diffstat (limited to 'Tests/RunCMake/string/Join.cmake')
-rw-r--r-- | Tests/RunCMake/string/Join.cmake | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/Tests/RunCMake/string/Join.cmake b/Tests/RunCMake/string/Join.cmake new file mode 100644 index 0000000..081f1e4 --- /dev/null +++ b/Tests/RunCMake/string/Join.cmake @@ -0,0 +1,16 @@ +string(JOIN % out) +if(NOT out STREQUAL "") + message(FATAL_ERROR "\"string(JOIN % out)\" set out to \"${out}\"") +endif() +string(JOIN % out a) +if(NOT out STREQUAL "a") + message(FATAL_ERROR "\"string(JOIN % out a)\" set out to \"${out}\"") +endif() +string(JOIN % out a "b") +if(NOT out STREQUAL "a%b") + message(FATAL_ERROR "\"string(JOIN % out a \"b\")\" set out to \"${out}\"") +endif() +string(JOIN :: out a "b") +if(NOT out STREQUAL "a::b") + message(FATAL_ERROR "\"string(JOIN :: out a \"b\")\" set out to \"${out}\"") +endif() |