@pytest.mark.vcr(before_record_response=...)
behaves differently when recording and playing back
#100
Labels
@pytest.mark.vcr(before_record_response=...)
behaves differently when recording and playing back
#100
Describe the bug
If I use a
before_record_response=
callback which modifies the response, the original response is used when the response is being recorded, and the modified response when it's being played back.To Reproduce
Steps to reproduce the behavior:
test_modified_response.py
:.yaml
file has the modified content:Expected behavior
For the example above, both test runs should pass.
More generally, the modified response should be returned to the calling HTTP client also when it's being recorded.
Environment (please complete the following information):
The text was updated successfully, but these errors were encountered: