Skip to content

Conversation

@sgoel
Copy link
Collaborator

@sgoel sgoel commented Dec 23, 2024

These two data structures need to stay in sync so that the rail routing service operates as expected.

The values in RailwayClass are used for styling the ways The values in RailAccessParser are used for routing over those ways.

Summary of changes:

  • NARROW_GAUGE - removed
  • MONORAIL - added
  • PROPOSED - added

These two data structures need to stay in sync so that the
rail routing service operates as expected.

The values in `RailwayClass` are used for styling the ways
The values in `RailAccessParser` are used for routing
over those ways.

Summary of changes:
- `NARROW_GAUGE` - removed
- `MONORAIL` - added
- `PROPOSED` - added
@sgoel sgoel requested a review from brookeangel December 23, 2024 23:06
parser.handleWayTags(edgeId, edgeIntAccess, way, relFlags);
assertEquals(RailwayClass.PROPOSED, classEnc.getEnum(false, edgeId, edgeIntAccess));

edgeIntAccess = new ArrayEdgeIntAccess(1);

Choose a reason for hiding this comment

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

Are these tests that came with open rail routing? I don't find them particularly readable 😅 are they just asserting that the values exist in the enum?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

yeah, they mostly came with the project. We added some additional ones as well. The test is actually exercising the class and making expectations on the output based on the inputs.

@sgoel sgoel merged commit 0e49e2b into master Dec 23, 2024
1 check passed
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.

3 participants