Repository navigation
ci: run recovery-safety unit tests in host contribution workflow - #68
Merged
Merged
Conversation
The oomwoo_recovery_safety package ships unit tests for the recovery ladder (guaranteed termination + safety-pause behavior), but they were not exercised by CI. The adapter tests stub rclpy via sys.modules, so the whole suite runs with just pytest and no ROS graph. Add a pytest install step and run the suite with PYTHONPATH set to the package root.
Collaborator
|
Thank you! |
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.
Proposal
Add the
oomwoo_recovery_safetyunit tests to thepythonjob inhost-contribution-tests.yml. They run on pushes tomainand on pull requests.This is a proposal. It adds
pytestto a job that currently runs only stdlibunittestwith nopip install. That relaxes the job's dependency-freeboundary. Your call whether the trade is worth it.
Why
recovery-safetyhandles bounded recovery escalation and safety-event pauses.rclpyviasys.modules.Scope
colcon build/test/test-resultpath, which buildsand tests in a ROS 2 environment.
Change
Two steps added to the
pythonjob:pytestPYTHONPATH="$PWD" python3 -m pytest test -qin the package root (rclpystubbed)Verification
Ran the updated workflow on a fork. All steps passed, including the new
recovery-safety step. It reported 13 passed (~0.04s in that run).
Trade-off
pytest+ onepip installto a stdlib-only job. Unit coverageonly, not full ROS integration.