diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/CMakeLists.txt | 45 |
1 files changed, 32 insertions, 13 deletions
diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index db9160c..53b3949 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -1,6 +1,3 @@ -# Setup testing -enable_testing() - #add_compile_options(-g -fsanitize=address) add_compile_options(-isystem ${gtest_SOURCE_DIR}/include) @@ -20,29 +17,51 @@ if(WITH_SYSTEMD OR WITH_SYSTEMD_WATCHDOG OR WITH_SYSTEMD_JOURNAL) endif() add_executable(gtest_dlt_common gtest_dlt_common.cpp) +target_link_libraries(gtest_dlt_common ${DLT_LIBRARIES}) +add_test(NAME gtest_dlt_common + COMMAND gtest_dlt_common + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) + add_executable(gtest_dlt_user gtest_dlt_user.cpp) +target_link_libraries(gtest_dlt_user ${DLT_LIBRARIES}) +add_test(NAME gtest_dlt_user + COMMAND gtest_dlt_user + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) + add_executable(gtest_dlt_daemon_common gtest_dlt_daemon_common.cpp ../src/daemon/dlt_daemon_common.c) +target_link_libraries(gtest_dlt_daemon_common ${DLT_LIBRARIES}) +add_test(NAME gtest_dlt_daemon_common + COMMAND gtest_dlt_daemon_common + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) + add_executable(dlt_test_receiver dlt_test_receiver.c) +target_link_libraries(dlt_test_receiver dlt) + add_executable(dlt_env_ll_unit_test dlt_env_ll_unit_test.cpp) +target_link_libraries(dlt_env_ll_unit_test ${DLT_LIBRARIES}) +add_test(NAME dlt_env_ll_unit_test + COMMAND gtest_dlt_common + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) + add_executable(dlt-test-preregister-context dlt-test-preregister-context.c) +target_link_libraries(dlt-test-preregister-context ${DLT_LIBRARIES}) + add_executable(gtest_dlt_daemon_gateway gtest_dlt_daemon_gateway.cpp ${systemd_SRCS}) +target_link_libraries(gtest_dlt_daemon_gateway ${DLT_DAEMON_LIBRARIES}) + add_executable(gtest_dlt_daemon_event_handler gtest_dlt_daemon_event_handler.cpp ${systemd_SRCS}) +target_link_libraries(gtest_dlt_daemon_event_handler ${DLT_DAEMON_LIBRARIES}) +add_test(NAME gtest_dlt_daemon_event_handler + COMMAND gtest_dlt_daemon_event_handler + WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) + add_executable(gtest_dlt_daemon_offline_log gtest_dlt_daemon_offline_log.cpp ${systemd_SRCS}) +target_link_libraries(gtest_dlt_daemon_offline_log ${DLT_DAEMON_LIBRARIES}) if(WITH_DLT_SHM_ENABLE) add_executable(gtest_dlt_shm gtest_dlt_shm.cpp) endif(WITH_DLT_SHM_ENABLE) -target_link_libraries(gtest_dlt_common ${DLT_LIBRARIES}) -target_link_libraries(gtest_dlt_user ${DLT_LIBRARIES}) -target_link_libraries(gtest_dlt_daemon_common ${DLT_LIBRARIES}) -target_link_libraries(dlt_test_receiver dlt) -target_link_libraries(dlt_env_ll_unit_test ${DLT_LIBRARIES}) -target_link_libraries(dlt-test-preregister-context ${DLT_LIBRARIES}) -target_link_libraries(gtest_dlt_daemon_gateway ${DLT_DAEMON_LIBRARIES}) -target_link_libraries(gtest_dlt_daemon_event_handler ${DLT_DAEMON_LIBRARIES}) -target_link_libraries(gtest_dlt_daemon_offline_log ${DLT_DAEMON_LIBRARIES}) - if(WITH_DLT_SHM_ENABLE) target_link_libraries(gtest_dlt_shm ${DLT_DAEMON_LIBRARIES}) endif(WITH_DLT_SHM_ENABLE) |