JVM version of Pact. Enables consumer driven contract testing, providing a mock service and DSL for the consumer project, and interaction playback and verification for the service provider project.
Hi All
can anyone please help me in validating Provider with Request headers , please find my below code snippets Pact files and error I am getting while Validating the Provider
Hi All can anyone please help me in validating Provider with Request headers , please find my below code snippets Pact files and error I am getting while Validating the Provider
Pact File:-
{ "provider": { "name": "GetCitizenProvider" }, "consumer": { "name": "ServiceabilityConsumer" }, "interactions": [ { "description": "Receiving Citizen Get Request", "request": { "method": "GET", "path": "/citizen/1", "headers": { "Language": "en" } }, "response": { "status": 200, "headers": { "Content-Type": "application/json" }, "body": { "name": "string", "id": 100 }, "matchingRules": { "body": { "$.id": { "matchers": [ { "match": "integer" } ], "combine": "AND" }, "$.name": { "matchers": [ { "match": "type" } ], "combine": "AND" } } }, "generators": { "body": { "$.id": { "type": "RandomInt", "min": 0, "max": 2147483647 }, "$.name": { "type": "RandomString", "size": 20 } } } }, "providerStates": [ { "name": "Request for getting Citizen Data" } ] } ], "metadata": { "pactSpecification": { "version": "3.0.0" }, "pact-jvm": { "version": "4.0.10" } } }