-
Notifications
You must be signed in to change notification settings - Fork 1k
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
add stopPositionInPattern in Stoptime in GTFS GraphQL API #6204
add stopPositionInPattern in Stoptime in GTFS GraphQL API #6204
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## dev-2.x #6204 +/- ##
=============================================
- Coverage 69.91% 69.72% -0.19%
+ Complexity 17736 17669 -67
=============================================
Files 2006 2007 +1
Lines 75526 75648 +122
Branches 7730 7741 +11
=============================================
- Hits 52804 52749 -55
- Misses 20036 20185 +149
- Partials 2686 2714 +28 ☔ View full report in Codecov by Sentry. |
stopIndex is considered an implementation detail in OTP which shouldn't be exposed, while stopPositionInPattern is guaranteed to run from 0 to n-1.
71aca89
to
b7d0dbe
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Use this new field in some integration test(s).
Summary
Add
stopIndex
inStoptime
model in GTFS GraphQL API.The purpose of this field is to find the absolute position in a pattern, such as in conjunction with the pattern in
Stop.stoptimesForPatterns
.Although the
stopIndex
field is used as the current implementation, it is considered an implementation detail, and this fetcher must return 0 to n-1 regardless of the implementation detail.Issue
Closes #6026
Unit tests
The fetcher code is not tested at all and is untestable, but if possible the fetcher should be tested to always return 0 to n-1.
Documentation
Added in GraphQL.