Hi Team, How can i mock api in wiremock so that it...
# help
a
Hi Team, How can i mock api in wiremock so that it throw resource access exception?
o
Hmm. Do you expect
resource access exception
to be return in response? You can definitely do that, but exception propagation to HTTP response depends on a Web framework you use. Ultimately, you need to set the response code, headers and the body to follow the response specification of your API provider
a
What response code and header shall i set so that on calling this api, i should get an error as resource access exception. i.e unable to access resource
o
It depends on your Server API specification and client implementation. There is no standard for sending exceptions over HTTP
a
Thanks @Oleg Nenashev