mirror of
https://github.com/public-transport/db-vendo-client.git
synced 2025-02-23 15:19:35 +02:00
E2E/integration validation logic: handle missing leg.alternatives[].when
This commit is contained in:
parent
17e08acfbb
commit
2d3c0d6a94
1 changed files with 3 additions and 1 deletions
|
@ -310,7 +310,9 @@ const createValidateJourneyLeg = (cfg) => {
|
|||
a.ok(alt.direction, n + '.direction must not be empty')
|
||||
}
|
||||
|
||||
if (alt.when !== null) {
|
||||
assertValidWhen(alt.when, cfg.when, n + '.when')
|
||||
}
|
||||
if (alt.delay !== null) {
|
||||
a.strictEqual(typeof alt.delay, 'number', n + '.delay must be a number')
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue