Skip to content

Restore exported BT util test files after cmake revamp #4652

@aosmw

Description

@aosmw

Bug report

With the cmake revamp the intent of #3372 has been lost.
In order to have users write tests for bt nodes in order modules, the test utility files must be installed/exported.

Steps to reproduce issue

Expected behavior

rm -fr install/nav2_behavior_tree
colcon build --packages-select nav2_behavior_tree
find install -name test_service.hpp
install/nav2_behavior_tree/include/nav2_behavior_tree/nav2_behavior_tree/test/utils/test_service.hpp

Actual behavior

test_service.hpp not found.

@clalancette possible fix... is this enough?

--- a/src/navigation2/nav2_behavior_tree/CMakeLists.txt
+++ b/src/navigation2/nav2_behavior_tree/CMakeLists.txt
@@ -256,6 +256,10 @@ install(DIRECTORY include/
   DESTINATION include/${PROJECT_NAME}
 )
 
+install(DIRECTORY test/utils/
+  DESTINATION include/${PROJECT_NAME}/nav2_behavior_tree/test/utils

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions