Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test(path_generator): add tests for turn signal activation feature #253

Merged

Conversation

mitukou1109
Copy link
Contributor

Description

This PR adds tests for turn signal activation feature of path_generator.

How was this PR tested?

colcon test --packages-select autoware_path_generator --event-handlers console_cohesion+

gives the following result (excerpt):

1: [----------] 6 tests from UtilsTest
1: [ RUN      ] UtilsTest.getPreviousLaneletWithinRoute
1: [       OK ] UtilsTest.getPreviousLaneletWithinRoute (30 ms)
1: [ RUN      ] UtilsTest.getNextLaneletWithinRoute
1: [       OK ] UtilsTest.getNextLaneletWithinRoute (28 ms)
1: [ RUN      ] UtilsTest.getLaneletsWithinRouteUpTo
1: [       OK ] UtilsTest.getLaneletsWithinRouteUpTo (26 ms)
1: [ RUN      ] UtilsTest.getLaneletsWithinRouteAfter
1: [       OK ] UtilsTest.getLaneletsWithinRouteAfter (24 ms)
1: [ RUN      ] UtilsTest.getLaneletsWithinRoute
1: [       OK ] UtilsTest.getLaneletsWithinRoute (26 ms)
1: [ RUN      ] UtilsTest.getTurnSignalRequiredEndPoint
1: [       OK ] UtilsTest.getTurnSignalRequiredEndPoint (25 ms)
1: [----------] 6 tests from UtilsTest (159 ms total)
1: 
1: [----------] 6 tests from GetTurnSignalTest
1: [ RUN      ] GetTurnSignalTest.getTurnSignal/EgoIsStoppingAndBeforeDesiredStartPoint
1: [       OK ] GetTurnSignalTest.getTurnSignal/EgoIsStoppingAndBeforeDesiredStartPoint (25 ms)
1: [ RUN      ] GetTurnSignalTest.getTurnSignal/EgoIsStoppingAndAheadOfDesiredStartPoint
1: [       OK ] GetTurnSignalTest.getTurnSignal/EgoIsStoppingAndAheadOfDesiredStartPoint (26 ms)
1: [ RUN      ] GetTurnSignalTest.getTurnSignal/EgoIsMovingAndAheadOfDesiredStartPoint
1: [       OK ] GetTurnSignalTest.getTurnSignal/EgoIsMovingAndAheadOfDesiredStartPoint (25 ms)
1: [ RUN      ] GetTurnSignalTest.getTurnSignal/EgoIsInRequiredSection
1: [       OK ] GetTurnSignalTest.getTurnSignal/EgoIsInRequiredSection (26 ms)
1: [ RUN      ] GetTurnSignalTest.getTurnSignal/EgoIsInDesiredSection
1: [       OK ] GetTurnSignalTest.getTurnSignal/EgoIsInDesiredSection (24 ms)
1: [ RUN      ] GetTurnSignalTest.getTurnSignal/EgoIsAheadOfDesiredEndPoint
1: [       OK ] GetTurnSignalTest.getTurnSignal/EgoIsAheadOfDesiredEndPoint (26 ms)
1: [----------] 6 tests from GetTurnSignalTest (152 ms total)

Notes for reviewers

None.

Interface changes

None.

Effects on system behavior

None.

add tests
Signed-off-by: mitukou1109 <mitukou1109@gmail.com>
Copy link

github-actions bot commented Mar 10, 2025

Thank you for contributing to the Autoware project!

🚧 If your pull request is in progress, switch it to draft mode.

Please ensure:

@kosuke55 kosuke55 self-assigned this Mar 10, 2025

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
Co-authored-by: Kosuke Takeuchi <kosuke.tnp@gmail.com>
Copy link
Member

@youtalk youtalk left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
@youtalk youtalk enabled auto-merge (squash) March 18, 2025 00:06
@youtalk youtalk added the run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci) label Mar 18, 2025
Copy link

codecov bot commented Mar 18, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 19.27%. Comparing base (4cb18f5) to head (20d6e5f).
Report is 112 commits behind head on main.

Additional details and impacted files
@@             Coverage Diff             @@
##             main     #253       +/-   ##
===========================================
- Coverage   78.75%   19.27%   -59.48%     
===========================================
  Files          11       94       +83     
  Lines         193     4233     +4040     
  Branches       73      880      +807     
===========================================
+ Hits          152      816      +664     
- Misses         11     3313     +3302     
- Partials       30      104       +74     
Flag Coverage Δ
differential 19.27% <ø> (?)
total ?

☔ View full report in Codecov by Sentry.
📢 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.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
@youtalk youtalk requested a review from sasakisasaki as a code owner March 18, 2025 01:49
youtalk added 2 commits March 18, 2025 10:52

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
@youtalk
Copy link
Member

youtalk commented Mar 25, 2025

@autowarefoundation/autoware-core-global-codeowners @kosuke55 Please review this.

@youtalk youtalk requested review from kosuke55 and a team March 26, 2025 05:54
@kosuke55
Copy link
Contributor

I will check

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
@kosuke55
Copy link
Contributor

memo of test lane ids.

image

image

image

Copy link
Contributor

@kosuke55 kosuke55 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment on lines +139 to +140
const auto result = utils::get_turn_signal_required_end_point(
planner_data_.lanelet_map_ptr->laneletLayer.get(lane_id), angle_threshold_deg);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1: result: 3760.89, 73749.4

the position seems ok

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1: 3760.89359759847
1: 73749.3592002149

image

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

oh, I wanted to add position check but mistakenly approved and merged..

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

send PR #323

@youtalk youtalk merged commit ca53328 into autowarefoundation:main Mar 26, 2025
24 of 26 checks passed
@mitukou1109 mitukou1109 deleted the test/path_generator_turn_signal branch March 27, 2025 00:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
run:build-and-test-differential Mark to enable build-and-test-differential workflow. (used-by-ci)
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants