Skip to content

Commit

Permalink
Append test labels instead of override them
Browse files Browse the repository at this point in the history
Signed-off-by: jparisu <[email protected]>
  • Loading branch information
jparisu committed Jun 23, 2023
1 parent adc964d commit 965b2cf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cmake_utils/cmake/test/test_labels.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,10 @@ macro(check_and_add_tests_label TEST_NAME TEST_LABEL_LIST LABEL)

if(${TEST_NAME} IN_LIST "${TEST_LABEL_LIST}")
message(STATUS "Setting label ${LABEL} to test ${TEST_NAME}")
set_property(TEST ${TEST_NAME} PROPERTY LABELS ${LABEL})
# NOTE: set_property override other labels, it must append new label
get_property(CURRENT_LABELS TEST ${TEST_NAME} PROPERTY LABELS)
list(APPEND CURRENT_LABELS ${LABEL})
set_property(TEST ${TEST_NAME} PROPERTY LABELS ${CURRENT_LABELS})
endif()

endmacro()
Expand Down

0 comments on commit 965b2cf

Please sign in to comment.