Open membersound opened 4 years ago
Could you enhance .expect() with a parameter? Maybe with the use of RequestMatcher?
.expect()
RequestMatcher
server.expect(RequestMatcher... matcher).withPath("/api/v1/users").andReturn(200, "admin");
So it could be possible to return results based on the send request (especially important when multiple async requests are send to the mockWebServer).
@membersound : Would you like to create a PR to add this feature?
Could you enhance
.expect()
with a parameter? Maybe with the use ofRequestMatcher
?server.expect(RequestMatcher... matcher).withPath("/api/v1/users").andReturn(200, "admin");
So it could be possible to return results based on the send request (especially important when multiple async requests are send to the mockWebServer).