Skip to content

Initial implementation of via search - #4554

Merged
TimMickelsonSkanetrafiken merged 12 commits into
opentripplanner:dev-2.xfrom
Skanetrafiken:4494_via_search_part_d
Nov 17, 2022
Merged

Initial implementation of via search#4554
TimMickelsonSkanetrafiken merged 12 commits into
opentripplanner:dev-2.xfrom
Skanetrafiken:4494_via_search_part_d

Conversation

@TimMickelsonSkanetrafiken

Copy link
Copy Markdown
Contributor

Summary

Via searches - Part D

- Worker to find trips with Via points
- Unit test for ViaRoutingWorker

Issue

#4494

Unit tests

  • Unit test ViaRoutingWorker for trip from A to B via C validating result.

	- Worker to find trips with Via points
	- Unit test for ViaRoutingWorker
@TimMickelsonSkanetrafiken TimMickelsonSkanetrafiken added !New Feature A functional feature targeting the end user. Entur On Entur Roadmap Skanetrafiken On skanetrafikens roadmap labels Oct 27, 2022
@codecov-commenter

codecov-commenter commented Oct 27, 2022

Copy link
Copy Markdown

Codecov Report

Base: 60.42% // Head: 60.52% // Increases project coverage by +0.10% 🎉

Coverage data is based on head (d378163) compared to base (94f9175).
Patch coverage: 80.12% of modified lines in pull request are covered.

Additional details and impacted files
@@              Coverage Diff              @@
##             dev-2.x    #4554      +/-   ##
=============================================
+ Coverage      60.42%   60.52%   +0.10%     
- Complexity     12163    12216      +53     
=============================================
  Files           1578     1584       +6     
  Lines          63256    63483     +227     
  Branches        6986     7006      +20     
=============================================
+ Hits           38221    38426     +205     
- Misses         22854    22872      +18     
- Partials        2181     2185       +4     
Impacted Files Coverage Δ
...nner/ext/fares/impl/AddingMultipleFareService.java 85.18% <ø> (ø)
...tripplanner/ext/fares/impl/DefaultFareService.java 90.18% <ø> (ø)
...tripplanner/ext/fares/impl/NycFareServiceImpl.java 0.00% <ø> (ø)
.../fares/impl/TimeBasedVehicleRentalFareService.java 0.00% <ø> (ø)
...g/opentripplanner/ext/fares/model/FareProduct.java 50.00% <ø> (ø)
...graphqlapi/datafetchers/LegacyGraphQLfareImpl.java 83.33% <ø> (ø)
...va/org/opentripplanner/api/mapping/FareMapper.java 54.23% <ø> (ø)
...pentripplanner/gtfs/mapping/FareProductMapper.java 58.33% <ø> (ø)
...er/gtfs/mapping/GTFSToOtpTransitServiceMapper.java 95.23% <ø> (-0.06%) ⬇️
...va/org/opentripplanner/routing/RoutingService.java 26.66% <0.00%> (-1.91%) ⬇️
... and 40 more

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report at Codecov.
📢 Do you have feedback about the report comment? Let us know in this issue.

@TimMickelsonSkanetrafiken TimMickelsonSkanetrafiken changed the title Issue #4494Via search - Pard D Via search - Pard D Oct 27, 2022
@leonardehrenfried leonardehrenfried changed the title Via search - Pard D Initial implementation of via search Oct 27, 2022
Comment thread src/main/java/org/opentripplanner/routing/api/request/request/ViaLocation.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/api/response/ViaRoutingResponse.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/algorithm/via/ViaRoutingWorker.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/algorithm/via/ViaRoutingWorker.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/algorithm/via/ViaRoutingWorker.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/algorithm/via/ViaRoutingWorker.java Outdated
Comment thread src/test/java/org/opentripplanner/routing/algorithm/via/TestViaRoutingWorker.java Outdated
@t2gran t2gran modified the milestones: 2.2, 2.3 Nov 1, 2022
	- RouteViaRequest removed reference to RouteRequest
    - ViaLocation with default values for maxSlack, minSlack
	- ViaRoutingWorker with sensible name on predicate
	- Rename TestViaRoutingWorker to ViaRoutingWorkerTest
Comment thread src/main/java/org/opentripplanner/routing/algorithm/via/ViaRoutingWorker.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/algorithm/via/ViaRoutingWorker.java Outdated
	- Utility function to create validation exception
	- null check on ViaLocation constructor
	- Refactor RouteViaRequest with Builder pattern
@hannesj
hannesj marked this pull request as ready for review November 8, 2022 09:43
@hannesj
hannesj requested a review from a team as a code owner November 8, 2022 09:43
Comment thread src/main/java/org/opentripplanner/routing/api/request/request/ViaLocation.java Outdated
Comment thread src/main/java/org/opentripplanner/routing/api/request/RouteRequest.java Outdated
private boolean timetableView;
private boolean arriveBy;
private Locale locale;
private JourneyRequest journey;

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
private JourneyRequest journey;

} else {
this.request.setTo(request.routeRequest().to());
}

@hannesj hannesj Nov 9, 2022

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
this.request.setJourney(v.journeyRequest());

@TimMickelsonSkanetrafiken
TimMickelsonSkanetrafiken merged commit 69cd2aa into opentripplanner:dev-2.x Nov 17, 2022
t2gran pushed a commit that referenced this pull request Nov 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Entur On Entur Roadmap !New Feature A functional feature targeting the end user. Skanetrafiken On skanetrafikens roadmap

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants