ScriptWithArgs.cmake 465 B

12345678910111213141516
  1. set(CTEST_RUN_CURRENT_SCRIPT 0)
  2. macro(check_arg name expected_value)
  3. message("${name}='${${name}}'")
  4. if(NOT "${${name}}" STREQUAL "${expected_value}")
  5. message(FATAL_ERROR "unexpected ${name} value '${${name}}', expected '${expected_value}'")
  6. endif()
  7. endmacro()
  8. check_arg(arg1 "this")
  9. check_arg(arg2 "that")
  10. check_arg(arg3 "the other")
  11. check_arg(arg4 "this is the fourth")
  12. check_arg(arg5 "the_fifth")
  13. check_arg(arg6 "value-with-type")
  14. check_arg(arg7 "")