pytest-vcr
pytest-vcr copied to clipboard
add --vcr-mode=refresh pseudo mode
--vcr-record=all
doesn't actually re-record the cassette but keeps or update (if there is a match) any previous episode and append the new ones.(see an example).
That's the reason why we generally recommend to delete the yaml file in advance and recreate it from scratch, but it's tedious. (and this is particularly important if the test match on the request's body)
--vcr-record=refresh
delete and start recording from scratch.
@ktosiek may you consider merging this?
@mgaitan As this plugin looks abandoned, may I suggest you try out pytest-recording instead? It has a fully compatible API with this plugin. We have the rewrite
record mode, which could be exactly what you're looking for :)