From 550e8bafbfd9433d9cd5c925beb4c00dacae584b Mon Sep 17 00:00:00 2001 From: Leonard Ehrenfried Date: Sat, 5 Oct 2024 09:58:20 +0200 Subject: [PATCH] Move walk step tests to planConnection --- .../apis/gtfs/expectations/walk-steps.json | 60 ++++++++++--------- .../apis/gtfs/queries/walk-steps.graphql | 34 +++++++---- 2 files changed, 52 insertions(+), 42 deletions(-) diff --git a/src/test/resources/org/opentripplanner/apis/gtfs/expectations/walk-steps.json b/src/test/resources/org/opentripplanner/apis/gtfs/expectations/walk-steps.json index 703663dc7ec..be584a875be 100644 --- a/src/test/resources/org/opentripplanner/apis/gtfs/expectations/walk-steps.json +++ b/src/test/resources/org/opentripplanner/apis/gtfs/expectations/walk-steps.json @@ -1,35 +1,37 @@ { "data" : { - "plan" : { - "itineraries" : [ + "planConnection" : { + "edges" : [ { - "legs" : [ - { - "steps" : [ - { - "streetName" : "street", - "area" : false, - "relativeDirection" : "DEPART", - "absoluteDirection" : "NORTHEAST" - }, - { - "streetName" : "elevator", - "area" : false, - "relativeDirection" : "ELEVATOR", - "absoluteDirection" : null - } - ] - }, - { - "steps" : [ ] - }, - { - "steps" : [ ] - }, - { - "steps" : [ ] - } - ] + "node" : { + "legs" : [ + { + "steps" : [ + { + "streetName" : "street", + "area" : false, + "relativeDirection" : "DEPART", + "absoluteDirection" : "NORTHEAST" + }, + { + "streetName" : "elevator", + "area" : false, + "relativeDirection" : "ELEVATOR", + "absoluteDirection" : null + } + ] + }, + { + "steps" : [ ] + }, + { + "steps" : [ ] + }, + { + "steps" : [ ] + } + ] + } } ] } diff --git a/src/test/resources/org/opentripplanner/apis/gtfs/queries/walk-steps.graphql b/src/test/resources/org/opentripplanner/apis/gtfs/queries/walk-steps.graphql index c88958840d4..dd2b96395ad 100644 --- a/src/test/resources/org/opentripplanner/apis/gtfs/queries/walk-steps.graphql +++ b/src/test/resources/org/opentripplanner/apis/gtfs/queries/walk-steps.graphql @@ -1,18 +1,26 @@ { - plan( - fromPlace: "from" - toPlace: "to" - date: "2023-02-15" - time: "11:37" - transportModes: [{ mode: WALK }] + planConnection( + origin: { + location: { coordinate: { latitude: 45.5552, longitude: -122.6534 } } + } + destination: { + location: { coordinate: { latitude: 45.4908, longitude: -122.5519 } } + } + dateTime: { earliestDeparture: "2023-06-13T14:30-07:00" } + modes: { + direct: [WALK] + transit: { transit: [{ mode: BUS }, { mode: RAIL }] } + } ) { - itineraries { - legs { - steps { - streetName - area - relativeDirection - absoluteDirection + edges { + node { + legs { + steps { + streetName + area + relativeDirection + absoluteDirection + } } } }