@@ -5,15 +5,10 @@ if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "Clang")
55 add_compile_options (-Wall -Wextra -Wpedantic )
66endif ()
77
8- # find dependencies
8+ # Dependencies
99find_package (ament_cmake REQUIRED )
1010find_package (ament_cmake_python REQUIRED )
1111find_package (rclpy REQUIRED )
12- find_package (ament_cmake_pytest REQUIRED )
13-
14- # uncomment the following section in order to fill in
15- # further dependencies manually.
16- # find_package(<dependency> REQUIRED)
1712
1813ament_python_install_package (${PROJECT_NAME} )
1914
@@ -22,6 +17,11 @@ install(PROGRAMS
2217 DESTINATION lib/${PROJECT_NAME}
2318)
2419
20+ # -----------------------------
21+ # Tests
22+ # -----------------------------
23+
24+
2525if (BUILD_TESTING)
2626 find_package (ament_lint_auto REQUIRED )
2727 # the following line skips the linter which checks for copyrights
@@ -34,13 +34,21 @@ if(BUILD_TESTING)
3434 ament_lint_auto_find_test_dependencies ()
3535endif ()
3636
37+
3738if (BUILD_TESTING)
3839 find_package (ament_cmake_pytest REQUIRED )
40+
3941 ament_add_pytest_tests (
40- heartbeat_monitor_tests
41- tests
42+ TESTNAME heartbeat_monitor_tests
43+ TEST_PATH test
4244 TIMEOUT 60
4345 )
46+
47+ find_package (ament_lint_auto REQUIRED )
48+ set (ament_cmake_copyright_FOUND TRUE )
49+ set (ament_cmake_cpplint_FOUND TRUE )
50+ ament_lint_auto_find_test_dependencies ()
4451endif ()
52+
4553ament_package ()
4654
0 commit comments