I have a documentation test like the following:
@Test
public void testSearchingRoutes() throws Exception {
mockMvc.perform(get("/routes").param("startNear", "+42.297877,-71.485591").param("endNear", "+41.949915,-71.406392"))
.andExpect(status().isOk())
.andDo(document("search-routes-example"));
}
When I run this as part of my Maven build, a request-response.asciidoc is produced, but the sample curl request omits the query parameters.
Putting a breakpoint in the RoutesController shows me that the parameters are indeed received by the controller, so I believe I'm sending them correctly with MockMvc.
Any reason I would get a curl snippet like:
[source,bash]
----
$ curl http://localhost:8080/routes -i
----
for this request?
I have a documentation test like the following:
When I run this as part of my Maven build, a request-response.asciidoc is produced, but the sample curl request omits the query parameters.
Putting a breakpoint in the
RoutesControllershows me that the parameters are indeed received by the controller, so I believe I'm sending them correctly with MockMvc.Any reason I would get a curl snippet like:
[source,bash]
----
$ curl http://localhost:8080/routes -i
----
for this request?