Update test discovery
This commit is contained in:
@@ -61,12 +61,17 @@ if(YAZE_BUILD_TESTS)
|
|||||||
endif()
|
endif()
|
||||||
|
|
||||||
include(GoogleTest)
|
include(GoogleTest)
|
||||||
gtest_discover_tests(${suite_name})
|
if(WIN32)
|
||||||
|
gtest_discover_tests(${suite_name}
|
||||||
# Get the list of tests discovered for the target and apply the label.
|
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
|
||||||
get_target_property(suite_tests ${suite_name} TESTS)
|
DISCOVERY_TIMEOUT 60
|
||||||
if(suite_tests)
|
PROPERTIES LABELS "${label}"
|
||||||
set_tests_properties(${suite_tests} PROPERTIES LABELS "${label}")
|
)
|
||||||
|
else()
|
||||||
|
gtest_discover_tests(${suite_name}
|
||||||
|
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
|
||||||
|
PROPERTIES LABELS "${label}"
|
||||||
|
)
|
||||||
endif()
|
endif()
|
||||||
endfunction()
|
endfunction()
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user