ruby-changes:61522
From: David <ko1@a...>
Date: Fri, 5 Jun 2020 07:33:56 +0900 (JST)
Subject: [ruby-changes:61522] 0fb2a7fa1c (master): Fix `bin/rake spec:realworld:record`
https://git.ruby-lang.org/ruby.git/commit/?id=0fb2a7fa1c From 0fb2a7fa1cd9348fba04e15bbc115776f4cc6d0a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?David=20Rodr=C3=ADguez?= <deivid.rodriguez@r...> Date: Sun, 24 May 2020 11:20:02 +0200 Subject: Fix `bin/rake spec:realworld:record` Previously it was failing and not recording. Also, the `BUNDLER_SPEC_FORCE_RECORD` environment variable was forcing every request to be recorded, including duplicated requests to the same endpoint. That meant the recorded `versions` file would be incorrect because it would contain the result of the last request, which would be `304 NOT MODIFIED`. So, to rerecord, delete cassettes and let them be recorded when needed. diff --git a/spec/bundler/support/artifice/vcr.rb b/spec/bundler/support/artifice/vcr.rb index 150436f..1967028 100644 --- a/spec/bundler/support/artifice/vcr.rb +++ b/spec/bundler/support/artifice/vcr.rb @@ -31,7 +31,6 @@ class BundlerVCRHTTP < Net::HTTP https://github.com/ruby/ruby/blob/trunk/spec/bundler/support/artifice/vcr.rb#L31 def recorded_response? return true if ENV["BUNDLER_SPEC_PRE_RECORDED"] - return false if ENV["BUNDLER_SPEC_FORCE_RECORD"] request_pair_paths.all? {|f| File.exist?(f) } end -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/