Wim Deblauwe Wim Deblauwe - 3 months ago 25
Java Question

Is it possible to use @AutoConfigureRestDocs with restassured instead of mockmvc?

Spring Boot 1.4 introduces

(See http://docs.spring.io/spring-boot/docs/current-SNAPSHOT/reference/htmlsingle/#boot-features-testing-spring-boot-applications-testing-autoconfigured-rest-docs). The docs state:

It will automatically configure MockMvc to use Spring REST Docs and remove the need for Spring REST Docs' JUnit rule.

I would like to use the restassured support of Spring REST Docs instead of mockmvc. Can I do this with


No, not at the moment. @AutoConfigureRestDocs builds on top of Spring Boot's testing support being able to auto-configure MockMvc. There's no support for auto-configuring REST Assured which the REST Docs auto-configuration could then build upon. If it's something that you'd like to see in Spring Boot, please open an enhancement request.