From a7c69068c09bb85a744052026d8c6a41b32fcb2d Mon Sep 17 00:00:00 2001 From: Alfi Maulana Date: Sun, 14 Jan 2024 18:31:12 +0700 Subject: [PATCH] Update Catch2 example to use `catch_discover_tests` --- examples/catch2/CMakeLists.txt | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/examples/catch2/CMakeLists.txt b/examples/catch2/CMakeLists.txt index f4d3e226..2e171ae2 100644 --- a/examples/catch2/CMakeLists.txt +++ b/examples/catch2/CMakeLists.txt @@ -17,5 +17,7 @@ target_compile_features(CPMExampleCatch2 PRIVATE cxx_std_17) # ---- Enable testing ---- +include(Catch) + enable_testing() -add_test(CPMExampleCatch2 CPMExampleCatch2) +catch_discover_tests(CPMExampleCatch2)