Crow/tests/CMakeLists.txt
Luca Schlecker 44f51f4750 Crow's current features (ssl and compression) can now be enabled through 'CROW_FEATURES' instead of their own CMake variables.
The default features are the ones Crow was installed with but can be overridden by setting 'CROW_FEATURES' before the 'find_package' call.

Signed-off-by: Luca Schlecker <luca.schlecker@hotmail.com>
2022-04-04 20:36:57 +02:00

25 lines
606 B
CMake

cmake_minimum_required(VERSION 3.15)
project(crow_test)
include(${CMAKE_SOURCE_DIR}/cmake/compiler_options.cmake)
set(TEST_SRCS
unittest.cpp
)
add_executable(unittest ${TEST_SRCS})
target_link_libraries(unittest Crow::Crow)
add_warnings_optimizations(unittest)
if("${CMAKE_CXX_COMPILER_ID}" STREQUAL "GNU")
set_target_properties(unittest PROPERTIES COMPILE_FLAGS "--coverage -fprofile-arcs -ftest-coverage")
target_link_libraries(unittest gcov)
endif()
add_subdirectory(template)
add_subdirectory(multi_file)
if ("ssl" IN_LIST CROW_FEATURES)
add_subdirectory(ssl)
endif()
add_subdirectory(img)