opentripplanner / OpenTripPlanner

An open source multi-modal trip planner
http://www.opentripplanner.org
Other
2.13k stars 1.01k forks source link

fix: ensure consolidated transit leg carries over fare #5894

Closed daniel-heppner-ibigroup closed 1 month ago

daniel-heppner-ibigroup commented 1 month ago

Summary

The consolidated stop builder did not copy over the fare products, this PR fixes that so the API correctly returns fares for these legs.

Unit tests

I modified the existing test for the fare legs to check that the decorator doesn't drop the fares.

daniel-heppner-ibigroup commented 1 month ago

My initial fix caused other issues (thank you tests!) so I think this approach is better.

codecov[bot] commented 1 month ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 68.61%. Comparing base (e210605) to head (447375f). Report is 5 commits behind head on dev-2.x.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## dev-2.x #5894 +/- ## ============================================= - Coverage 68.61% 68.61% -0.01% + Complexity 16826 16824 -2 ============================================= Files 1927 1927 Lines 72928 72929 +1 Branches 7475 7475 ============================================= Hits 50041 50041 + Misses 20315 20314 -1 - Partials 2572 2574 +2 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.