Fix execution test setup and preemption - #760
Conversation
Pass the controller configuration through the spawner, reuse the executor that already owns the action client node while canceling, and only assert the test process exit code.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan includes up to 3 reviews per rolling hour; 2 remain after this review. 📝 WalkthroughWalkthroughThe pull request fixes ROS 2 controller configuration passing, narrows launch-test exit-code validation to the target process, and completes preemption cancellation through the local executor. ChangesExecution fixes
Estimated code review effort: 2 (Simple) | ~10 minutes Merge Risk: ⚪ Minimal · up to The changes correct test setup and preemption handling, with the reported focused, cross-distribution, sanitizer, static-analysis, and formatting checks passing; no actionable merge-blocking risk remains beyond normal review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
rhaschke
left a comment
There was a problem hiding this comment.
Thanks for handling this issue!
Fixes #759.
The execution test relied on controller-manager ROS arguments being forwarded
to controller nodes. Current
ros2_controlno longer does that, so the Pandatrajectory controller started without its
jointsparameter. The controllerfailed to load, the combined spawner stopped before starting the joint-state
broadcaster, and the test observed the self-colliding default state.
This passes the existing controller YAML explicitly through the spawner's
--param-fileoption.Once controller setup succeeds, the preemption case reaches a second issue:
Task::execute()waits for the cancel response with the freespin_until_future_complete(node, future)helper even though that node alreadybelongs to its local executor. Reusing the existing executor avoids adding the
node twice and preserves the expected
PREEMPTEDresult.Finally, the post-shutdown assertion now checks the actual test executable.
The previous all-process assertion also attributed an existing released
move_groupteardown crash to this MTC test; the same crash is present in theunmodified base CI run after the functional test process stops.
Validation:
clang-tidychecks with warnings as errors,and focused execution test passed
(
test_executionis intentionally disabled by the existing CMake conditionwhen
-fsanitizeis present)git diff --checkpassedSummary by CodeRabbit