How to enable verbose logging in non standalone wiremock

Set Notifier to ConsoleNotifier(true).

WireMockRule wireMockRule = new WireMockRule(WireMockConfiguration.options().port(8080).httpsPort(443)
.notifier(new ConsoleNotifier(true)).extensions(new ResponseTemplateTransformer(true)));

WireMock uses SLF4J. Set the level of the category com.github.tomakehurst.wiremock to TRACE. Consult the SLF4J manual to find out how to accomplish this in your case.


If you're using a JUnit Rule, you can set the notifier to verbose mode like this:

@Rule
public WireMockRule serviceMock = new WireMockRule(new WireMockConfiguration().notifier(new Slf4jNotifier(true)));

Tags:

Wiremock