From 9dbba877c30d45a32ee21d4ad591e9c2dd07f8c1 Mon Sep 17 00:00:00 2001 From: scawful Date: Tue, 14 Oct 2025 11:38:12 -0400 Subject: [PATCH] Update test discovery --- test/CMakeLists.txt | 17 +++++++++++------ 1 file changed, 11 insertions(+), 6 deletions(-) diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt index 7d9500ad..2aa5a741 100644 --- a/test/CMakeLists.txt +++ b/test/CMakeLists.txt @@ -61,12 +61,17 @@ if(YAZE_BUILD_TESTS) endif() include(GoogleTest) - gtest_discover_tests(${suite_name}) - - # Get the list of tests discovered for the target and apply the label. - get_target_property(suite_tests ${suite_name} TESTS) - if(suite_tests) - set_tests_properties(${suite_tests} PROPERTIES LABELS "${label}") + if(WIN32) + gtest_discover_tests(${suite_name} + WORKING_DIRECTORY ${CMAKE_BINARY_DIR} + DISCOVERY_TIMEOUT 60 + PROPERTIES LABELS "${label}" + ) + else() + gtest_discover_tests(${suite_name} + WORKING_DIRECTORY ${CMAKE_BINARY_DIR} + PROPERTIES LABELS "${label}" + ) endif() endfunction()