The "help" target is used to check if a particular target exists:
|
output = subprocess.check_output([ |
|
CMAKE_EXECUTABLE, '--build', path, '--target', 'help'], cwd=path) |
But when using the Ninja generator, the "tests" target does not seem to appear in the output of that command, and therefore is not built by a colcon build on a ROS package containing cmake such as:
if(CATKIN_ENABLE_TESTING)
find_package(rostest REQUIRED)
add_rostest_gtest(dummy_node_test test/dummy_node.test test/DummyNodeTest.cpp)
target_include_directories(dummy_node_test SYSTEM PRIVATE ${catkin_INCLUDE_DIRS})
target_link_libraries(dummy_node_test ${catkin_LIBRARIES})
endif()
This causes colcon test failures if rostest tries to launch the unbuilt test binary.
The "help" target is used to check if a particular target exists:
colcon-cmake/colcon_cmake/task/cmake/__init__.py
Lines 92 to 93 in 2e824fd
But when using the Ninja generator, the "tests" target does not seem to appear in the output of that command, and therefore is not built by a
colcon buildon a ROS package containing cmake such as:This causes
colcon testfailures if rostest tries to launch the unbuilt test binary.