Open otrosien opened 8 years ago
see spring cloud contract for an example.
The easiest way would be to provide call-backs so that the initial stub mappings can be customized.
com.github.tomakehurst.wiremock.stubbing.StubMapping.buildFrom(mappingDefinition);
So we'll end-up in: Map<String,Object> -> JSON String -> StubMapping -> callback to caller -> modified StubMapping -> JSON String.
At the moment the stub json is fixed by introspecting the request. Instead it should be possible to use and manipulate the wiremock stub in the test case.