Closed nkonev closed 8 years ago
I'm not 100% sure that I've understood the problem, but if I have, the section of the documentation that you've linked to describes what you need to do:
To configure a request’s context path, use the
contextPath
method onMockHttpServletRequestBuilder
.
Does that help?
Yes, it's (MockHttpServletRequestBuilder#contextPath
) solves the trouble, thanks!
I started with example from here spring-swagger2markup-demo In swagger-ui I can see "base path" which is set by affect of Spring Boot
server.contextPath
config property:aaa/v3
Obvously =), base path are presents in swagger's generated adocs:
But it ignored by restdocs .
I found what I can set scheme, host and port as described here doc.
It would be great if it could be set up and the basepath (probably among
withScheme()
,withHost()
,withPort()
) in restdocs too.