setErrorHandler
fun setErrorHandler(handler: suspend MockzillaHttpRequest.() -> MockzillaHttpResponse): EndpointConfiguration.Builder
The block called when a network request is made to this endpoint but Mockzilla decides to simulate a server failure.
Parameters
handler
Lambda invoked with the incoming request that returns the simulated error response.