vcr をオンにして、現在の例の名前をカセット名として使用できるようにする rspec フックを追加しています。
it "should have collaborators", :vcr => :once do
# web interactions
end
config.around(:each, :vcr => :once) do |example|
VCR.use_cassette(example.name, :record => :once) do
example.call
end
end
問題は、現在の例の名前を取得する方法がわからないことです (example.name は機能しません)。