I use MockRestAdapter
to return mock data in my tests, but I'd also like to test errors (401, 503, UnknownHostException
, etc) For SocketTimeoutException
, there's an API, but how about different response code?
I've tried MockWebServer
but no matter what I enqueue, I always get a 200 with the mock data from the adapter.
Aucun commentaire:
Enregistrer un commentaire