09/11/2023, 4:47 PM
Hello I'm seeking some help to understand how/when Helper extensions are applied. I'm using 2 types of stubs (which were working fine with Wiremock v2) : • returning a template file (using aResponse().withBodyFile(...)) • returning a dynamic data response (using a ResponseDefinitionTransformerV2 implementation)
Copy code
I'm trying to include data generated via a Helper class. I've been testing my code with Wiremock's trim
Copy code
{{trim request.headers.User-Agent}}
If that string is included in the template file, it is processed and replaced. If that string is included in in object included via withBody, it is no processed. Are helpers disabled when a ResponseDefinitionTransformerV2 is used ? Should I avoid using them both at the same time ? Is there anyway to debug that situation (some log level, Wiremock class looping through all extensions, for example) ? Feel free to ask for any precision, and thank you for any answer you can provide.