Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Option to raise an exception when a cassette needs to be re-recorded #734

Closed
adeeb1 opened this issue Feb 9, 2019 · 1 comment · May be fixed by #768
Closed

Option to raise an exception when a cassette needs to be re-recorded #734

adeeb1 opened this issue Feb 9, 2019 · 1 comment · May be fixed by #768

Comments

@adeeb1
Copy link

adeeb1 commented Feb 9, 2019

My tests run within a docker container in a Jenkins environment, and the test environment is reconstructed with each test run. As I understand it, if I first recorded a cassette a month ago and set the re_record_interval to 1 month, it will make a live API call every single time the cassette is run. This is because the cassette has expired, and although it updates the cassette file on the test environment, that update will not be committed to my repository. So every time the test environment is spun up again, it will see an expired cassette and make a live API call.

What do you think about adding an option to raise an exception if a cassette has expired and needs to be re-recorded? That would cause my test suite to fail, and a developer would have to manually re-record the cassette locally and commit it to the repository.

@krainboltgreene
Copy link
Contributor

You can store cassettes elsewhere, see persistence documentation.

@vcr vcr locked and limited conversation to collaborators Feb 28, 2021

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
None yet
Projects
None yet
2 participants