Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我想模拟端点,例如。/notReachable那将无法连接。
/notReachable
如何实现这样的嘲讽?
可能是这样的,在wiremock站点wiremock faults上找到
stubFor(get(urlEqualTo("/fault")) .willReturn(aResponse().withFault(Fault.MALFORMED_RESPONSE_CHUNK)));