From 20219d74f0bb464f994982e2b7effca421fd0378 Mon Sep 17 00:00:00 2001 From: Benoit Blanchon Date: Wed, 23 Oct 2024 15:04:52 +0200 Subject: [PATCH] Tests: don't link `FailingBuilds` with `catch` --- extras/tests/CMakeLists.txt | 9 ++++++--- extras/tests/FailingBuilds/CMakeLists.txt | 2 +- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/extras/tests/CMakeLists.txt b/extras/tests/CMakeLists.txt index f79a3c92..212e31e2 100644 --- a/extras/tests/CMakeLists.txt +++ b/extras/tests/CMakeLists.txt @@ -5,15 +5,18 @@ set(CMAKE_CXX_STANDARD 11) set(CMAKE_CXX_STANDARD_REQUIRED ON) -add_subdirectory(catch) +link_libraries(ArduinoJson) -link_libraries(ArduinoJson catch) +# Failing builds should only link with ArduinoJson, not catch +add_subdirectory(FailingBuilds) + +add_subdirectory(catch) +link_libraries(catch) include_directories(Helpers) add_subdirectory(Cpp17) add_subdirectory(Cpp20) add_subdirectory(Deprecated) -add_subdirectory(FailingBuilds) add_subdirectory(IntegrationTests) add_subdirectory(JsonArray) add_subdirectory(JsonArrayConst) diff --git a/extras/tests/FailingBuilds/CMakeLists.txt b/extras/tests/FailingBuilds/CMakeLists.txt index 7ee4a46a..9a5f02cc 100644 --- a/extras/tests/FailingBuilds/CMakeLists.txt +++ b/extras/tests/FailingBuilds/CMakeLists.txt @@ -16,7 +16,7 @@ macro(build_should_fail target) set_tests_properties(${target} PROPERTIES WILL_FAIL TRUE - LABELS "WillFail;Catch" + LABELS "WillFail" ) endmacro()