vcrpy
vcrpy copied to clipboard
Cassette Naming Flexibility
trafficstars
Hi,
I wanted to know if I could name the cassettes based on the url it will be calling through the test functions? Since I have a chain of URLs that might be dynamically called in one test function, I don't want to save the cassette name by the test function name, rather I want to save the cassette based on the URLs it calls. I tried playing around with the configurational settings but what I found was that dynamically capturing URLs through before_record hook wasn't enough to name the cassette file as the context manager requires the cassette file path to be set before entering it. Is there a way to circumvent this?