Skip to content

Commit

Permalink
Use the same test as Python
Browse files Browse the repository at this point in the history
  • Loading branch information
ianthetechie committed Apr 30, 2024
1 parent fae852c commit 3e886c8
Showing 1 changed file with 11 additions and 19 deletions.
30 changes: 11 additions & 19 deletions __tests__/routing.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,33 +73,25 @@ const matrixRequest: MatrixRequest = {
id: "foobar",
sources: [
{
lat: 40.744014,
lon: -73.990508
lat: 58.891957,
lon: 22.726262
},
{
lat: 59.1558,
lon: 23.762758
}
],
targets: [
{
lat: 40.744014,
lon: -73.990508
},
{
lat: 40.739735,
lon: -73.979713
},
{
lat: 40.752522,
lon: -73.985015
},
{
lat: 40.750117,
lon: -73.983704
lat: 59.176153,
lon: 23.846605
},
{
lat: 40.750552,
lon: -73.993519
lat: 59.562853,
lon: 23.096114
}
],
costing: "pedestrian"
costing: "bicycle"
};

const matrixMockRes = {"units":"kilometers","sources":[{"lon":-73.990508,"lat":40.744014}],"targets":[{"lon":-73.990508,"lat":40.744014},{"lon":-73.979713,"lat":40.739735},{"lon":-73.985015,"lat":40.752522},{"lon":-73.983704,"lat":40.750117},{"lon":-73.993519,"lat":40.750552}],"sources_to_targets":[[{"distance":0,"time":0,"to_index":0,"from_index":0},{"distance":1.126,"time":829,"to_index":1,"from_index":0},{"distance":1.327,"time":969,"to_index":2,"from_index":0},{"distance":1.134,"time":840,"to_index":3,"from_index":0},{"distance":1.355,"time":986,"to_index":4,"from_index":0}]]};
Expand Down

0 comments on commit 3e886c8

Please sign in to comment.