wiremock / wiremock.org

WireMock website, powered by Jekyll. Contributions are welcome!
https://wiremock.org/
MIT License
11 stars 49 forks source link

Issue on Request Matching - Request with Form Parameters - Documentation #266

Closed rv3183 closed 5 months ago

rv3183 commented 5 months ago

Page

/docs/request-matching/

Details

Team, Was testing form paramaters feature in Wirmeock 3 and noticed syntax error in documentation. Example in documentation does not works because the willreturn method is at wrong place. stubFor(post(urlPathEqualTo("/mock")) .withFormParam("tool", equalTo("WireMock")) ).willReturn(ok()));

Suggested Edits

Replace with below snippet: stubFor(post(urlPathEqualTo("/mock")) .withFormParam("tool", equalTo("WireMock")) .willReturn(ok()));

References

https://wiremock.org/docs/request-matching/#request-with-form-parameters