From dd88cea0451a0fa91ff8d543caaf3b347cdd458d Mon Sep 17 00:00:00 2001 From: Jannis R Date: Mon, 20 Jul 2020 16:19:28 +0200 Subject: [PATCH] journeys E2E/integration tests: expect >=n results --- test/e2e/lib/journeys-station-to-address.js | 2 +- test/e2e/lib/journeys-station-to-poi.js | 2 +- test/e2e/lib/journeys-station-to-station.js | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/test/e2e/lib/journeys-station-to-address.js b/test/e2e/lib/journeys-station-to-address.js index cce06045..6ec3f9bd 100644 --- a/test/e2e/lib/journeys-station-to-address.js +++ b/test/e2e/lib/journeys-station-to-address.js @@ -9,7 +9,7 @@ const testJourneysStationToAddress = async (cfg) => { validate(t, res, 'journeysResult', 'res') const {journeys} = res - t.strictEqual(journeys.length, 3) + t.ok(journeys.length >= 3, 'journeys must have >=3 items') for (let i = 0; i < journeys.length; i++) { const j = journeys[i] diff --git a/test/e2e/lib/journeys-station-to-poi.js b/test/e2e/lib/journeys-station-to-poi.js index 474152de..03fa8a85 100644 --- a/test/e2e/lib/journeys-station-to-poi.js +++ b/test/e2e/lib/journeys-station-to-poi.js @@ -9,7 +9,7 @@ const testJourneysStationToPoi = async (cfg) => { validate(t, res, 'journeysResult', 'res') const {journeys} = res - t.strictEqual(journeys.length, 3) + t.ok(journeys.length >= 3, 'journeys must have >=3 items') for (let i = 0; i < journeys.length; i++) { const j = journeys[i] diff --git a/test/e2e/lib/journeys-station-to-station.js b/test/e2e/lib/journeys-station-to-station.js index c16fff73..cc3d0db0 100644 --- a/test/e2e/lib/journeys-station-to-station.js +++ b/test/e2e/lib/journeys-station-to-station.js @@ -8,7 +8,7 @@ const testJourneysStationToStation = async (cfg) => { validate(t, res, 'journeysResult', 'res') const {journeys} = res - t.strictEqual(journeys.length, 4) + t.ok(journeys.length >= 4, 'journeys must have >=4 items') for (let i = 0; i < journeys.length; i++) { const j = journeys[i] const n = `res.journeys[${i}]`