Skip to content

Integration tests for cubic and quintic splines with dynamics#1801

Open
srvald wants to merge 2 commits into
UniversalRobots:mainfrom
srvald:enhance_trajectory_tests
Open

Integration tests for cubic and quintic splines with dynamics#1801
srvald wants to merge 2 commits into
UniversalRobots:mainfrom
srvald:enhance_trajectory_tests

Conversation

@srvald

@srvald srvald commented May 27, 2026

Copy link
Copy Markdown
Contributor

Description

This PR resolves the issue where the passthrough_trajectory_controller integration tests were only verifying edge cases (position-only quintic splines with explicit zero-matrices).

We now explicitly test the full capabilities of the UR hardware interface regarding custom trajectory profiles.

Changes

  • Added test_cubic_trajectory: Test providing positions and zero velocities to evaluate the cubic spline.
  • Added test_cubic_trajectory_with_velocities: Test providing positions and explicit non-zero velocities to evaluate the cubic spline.
  • Added test_quintic_trajectory_with_velocities: Verify full quintic spline execution using non-zero velocities and accelerations.
  • Expanded test trajectory to a 4-waypoint forward-and-return cycle for the non-zero velocities and acceleration tests.

Related Issues

Fixes #1783

Testing

Tested via integration testing using ur_robot_driver alongside Docker URSim:

cd build/ur_robot_driver
ctest -R "integration_test_passthrough_controller" -V

Note

Low Risk
Changes are confined to integration tests in integration_test_passthrough_controller.py; no driver or controller runtime behavior is modified.

Overview
Expands passthrough trajectory controller integration coverage so cubic and quintic spline paths are exercised with more than position-only, all-zero dynamics.

Shared test data now uses a four-waypoint forward-and-return motion (replacing three coarse index steps) and adds TEST_TRAJECTORY_FULL with explicit per-waypoint velocities and accelerations. Existing tests that rely on TEST_TRAJECTORY inherit the richer waypoint set and timing.

New tests send FollowJointTrajectory goals through the passthrough controller and assert success for: cubic splines with zero velocities, cubic with non-zero velocities, and quintic with non-zero velocities and accelerations (alongside the existing quintic-with-zeros case).

Reviewed by Cursor Bugbot for commit 7176a82. Bugbot is set up for automated code reviews on this repo. Configure here.

@codecov

codecov Bot commented Jun 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 5.00%. Comparing base (1b121b7) to head (7176a82).
⚠️ Report is 584 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff            @@
##            main   #1801      +/-   ##
========================================
+ Coverage   3.59%   5.00%   +1.41%     
========================================
  Files         13      34      +21     
  Lines        947    4255    +3308     
  Branches     152     500     +348     
========================================
+ Hits          34     213     +179     
- Misses       843    4037    +3194     
+ Partials      70       5      -65     
Flag Coverage Δ
unittests 5.00% <ø> (+1.41%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Enhance passthrough trajectory controller tests

2 participants