The add method returns a BaseResponse, on which you can find calls using calls.
The add_callback method doesn't. Users can get calls from the generic RequestsMock object, but that requires searching for the right request, for which responses provides no native methods.
Solutions:
- Let
add_callback return BaseResponse (probably not possible)
- Add built-in way to search for calls on the
RequestsMock object, preferably those belonging to a specific response
The
addmethod returns aBaseResponse, on which you can find calls usingcalls.The
add_callbackmethod doesn't. Users can get calls from the genericRequestsMockobject, but that requires searching for the right request, for whichresponsesprovides no native methods.Solutions:
add_callbackreturnBaseResponse(probably not possible)RequestsMockobject, preferably those belonging to a specific response