summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/ExternalData/Semicolon1.cmake
blob: c8328608255abf1dc261c1e5db6305d507ebd66a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
include(ExternalData)
set(ExternalData_URL_TEMPLATES
  "file:///${CMAKE_CURRENT_SOURCE_DIR}/%(algo)/%(hash)"
  )
set(input Data.txt)
set(output ${CMAKE_CURRENT_BINARY_DIR}/Data.txt)
ExternalData_Expand_Arguments(Data args DATA{${input}} "a\\;b" "c;d" DATA{${input}})
set(expect "${output};a\\;b;c;d;${output}")
if("x${args}" STREQUAL "x${expect}")
  message(STATUS "Data arguments correctly transformed!")
else()
  message(FATAL_ERROR "Data arguments transformed to:\n  ${args}\n"
    "but we expected:\n  ${expect}")
endif()