The version of wiremock is 2.14.0 API
The command line for starting the wiremock used is as below:
java -jar wiremock-standalone-2.14.0.jar --port 8787 --verbose --record-mappings --match-headers requestHeader,mobileHeader
We tried the customizing the record and play using wiremock and we wanted to customize the request header specs wanted to add the matcher as “equalToJson” and wanted to add two additional parameters like the "ignoreArrayOrder" : false,"ignoreExtraElements" : true to the request headers but the error that we got is :
{
"errors": [
{
"code": 10,
"source": {
"pointer": "/captureHeaders/matcher"
},
"title": "Error parsing JSON",
"detail": "Unrecognized field \"matcher\" (class com.github.tomakehurst.wiremock.recording.CaptureHeadersSpec), not marked as ignorable"
}
]
}
The version of wiremock is 2.14.0 API The command line for starting the wiremock used is as below: java -jar wiremock-standalone-2.14.0.jar --port 8787 --verbose --record-mappings --match-headers requestHeader,mobileHeader We tried the customizing the record and play using wiremock and we wanted to customize the request header specs wanted to add the matcher as “equalToJson” and wanted to add two additional parameters like the "ignoreArrayOrder" : false,"ignoreExtraElements" : true to the request headers but the error that we got is : { "errors": [ { "code": 10, "source": { "pointer": "/captureHeaders/matcher" }, "title": "Error parsing JSON", "detail": "Unrecognized field \"matcher\" (class com.github.tomakehurst.wiremock.recording.CaptureHeadersSpec), not marked as ignorable" } ] }
The expected json Format is : "request" : { "url" : "/api/channel/datacardwidgets", "method" : "GET", "headers" : { "requestHeader" : { "equalToJson" : "{\"clientId\":\"1234\"}", "ignoreArrayOrder" : false, "ignoreExtraElements" : true } } },