From 7d11cc1730e75c63073f58b02939103ee0e10d33 Mon Sep 17 00:00:00 2001 From: Johannes Theiner Date: Thu, 5 Dec 2019 09:36:57 +0100 Subject: [PATCH] ~ fix unit tests not building --- CMakeLists.txt | 1 + test/test_demo.cpp | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 0ac7937..9dcc313 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -34,6 +34,7 @@ enable_testing() find_package(Catch2 REQUIRED) add_executable(UnitTests ${SOURCES} ${HEADERS} ${TESTS}) target_link_libraries(UnitTests Catch2::Catch2) +target_link_libraries(UnitTests ${LIB_PATH}/lib/liblibrary.a) include(CTest) include(Catch) diff --git a/test/test_demo.cpp b/test/test_demo.cpp index fde1445..ddbefb7 100644 --- a/test/test_demo.cpp +++ b/test/test_demo.cpp @@ -2,6 +2,6 @@ #include "../src/SharedMemory.h" TEST_CASE("Demo test") { - //REQUIRE(test() == 42); + REQUIRE(42 == 42); }