Question: does Pact's consumer driven contract testing support other types of response body than JSON? (E.g. raw HTML output?)
m
Matt (pactflow.io / pact-js / pact-go)
04/12/2023, 11:12 AM
Yes, it supports pretty much any content-type, albeit Matchers are only available on JSON and XML)
Matt (pactflow.io / pact-js / pact-go)
04/12/2023, 11:12 AM
We also have recently introduced a plugin framework, which would allow arbitrary protocols/content-types to be used, and matching can be used there if the plugin author implements it
Matt (pactflow.io / pact-js / pact-go)
04/12/2023, 11:12 AM
I suspect you could maybe, possible use the XML matching for HTML 😬