Expand the xacro tests over every backend - #17
Merged
Conversation
The docstring states why each spelling is rejected, which is what the assertions check. That the names once differed is not part of it.
The expansion test and the CI loop both ran with default args, which select mock hardware. The real backend is the one that emits a <ros2_control> block per bus -- three for lite_biped against mock's one -- so every hardware bring-up depended on a macro that nothing exercised. Parametrise over all four (use_mock_hardware, sim_mujoco) selections and add a test asserting the real backend emits one block per bus plus one per sensor, with distinct component names. Drop the mesh_root override from both: xacro ignores it, because the assembly never declares it as an arg. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EotyWG9YmYvg5xE2v3Zkpt
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The expansion test and the CI loop both ran with default args, which select mock hardware. The real backend is the one that emits a
<ros2_control>block per bus — three forlite_bipedagainst mock's one — so every hardware bring-up depended on a macro that nothing exercised.test_xacro_expands_and_check_urdfover all four(use_mock_hardware, sim_mujoco)selections, and do the same in the CI loop. 24 expansions now check out where 7 did.test_real_backend_emits_one_block_per_bus, asserting one block per bus plus one per sensor, with distinct component names. Negative-controlled: forcing a duplicate component name fails it.mesh_root:=override from both. The assembly never declaresmesh_rootas an arg, so xacro silently ignored it — the test comment claiming it avoided needing an installed ament workspace was false. The test passes only becausecheck_urdfnever resolvespackage://.Paired with Berkeley-Humanoids/humanoid_control_ros2#38.
🤖 Generated with Claude Code
https://claude.ai/code/session_01EotyWG9YmYvg5xE2v3Zkpt