mirror of
https://github.com/Kitware/CMake.git
synced 2026-04-23 06:47:08 -05:00
61929f936f
Due to add_command() being a macro it introduced excessive and
nonobvious escaping in different parts of the script. Because of
one of such places the resulting script would have an erroneous
${TEST_LIST} if the user data (in test parameters) had a semicolon.
To eliminate this non-obvious escaping, add_command() was converted
to function. Updated the escaping accordingly.
Fixes: #23059
7 lines
259 B
CMake
7 lines
259 B
CMake
list(LENGTH test_list_test_TESTS LIST_SIZE)
|
|
set(EXPECTED_SIZE 2)
|
|
if(NOT LIST_SIZE EQUAL ${EXPECTED_SIZE})
|
|
message("TEST_LIST should have ${EXPECTED_SIZE} elements but it has ${LIST_SIZE}")
|
|
message("The unexpected list: [${test_list_test_TESTS}]")
|
|
endif()
|