1
0
mirror of https://github.com/wjwwood/serial.git synced 2026-01-23 04:04:54 +08:00
serial/tests/CMakeLists.txt
Dan Rose 2df800d0fc
Revert "Remove test that breaks the build"
This reverts commit 7fe3be8d5f24db9837fff7e5b2fc45dcb464eef0.
2020-09-08 12:44:34 -05:00

16 lines
546 B
CMake

if(UNIX)
find_package(ament_cmake_gtest REQUIRED)
find_package(Boost REQUIRED)
ament_add_gtest(${PROJECT_NAME}-test unix_serial_tests.cc)
target_link_libraries(${PROJECT_NAME}-test ${PROJECT_NAME} ${Boost_LIBRARIES})
if(NOT APPLE)
target_link_libraries(${PROJECT_NAME}-test util)
endif()
if(NOT APPLE) # these tests are unreliable on macOS
ament_add_gtest(${PROJECT_NAME}-test-timer unit/unix_timer_tests.cc)
target_link_libraries(${PROJECT_NAME}-test-timer ${PROJECT_NAME})
endif()
endif()