Describe the issueverifySequence expects a list of request definitions, but the TypeScript type definition looks like this:
verifySequence(matchers: RequestDefinition[]): Promise<void | string>;.
If I pass an array as an argument, I get this error from MockServer:
Error: Failed: "1 error:
- instance type (array) does not match any allowed primitive type (allowed: [\"object\"]) for field \"/httpRequests/0\"
See: https://app.swaggerhub.com/apis/jamesdbloom/mock-server-openapi/5.10.x for OpenAPI Specification"`
Describe the issue
verifySequence
expects a list of request definitions, but the TypeScript type definition looks like this:verifySequence(matchers: RequestDefinition[]): Promise<void | string>;
.If I pass an array as an argument, I get this error from MockServer:
MockServer version 5.10.0
To Reproduce Call
verifySequence
with an array.Solution idea Change the type definition so
matchers
is a rest parameter:verifySequence(...matchers: RequestDefinition[]): Promise<void | string>;