vcr 2.0.0.beta1 → 2.0.0.beta2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/.gitignore +1 -0
- data/.travis.yml +3 -0
- data/CHANGELOG.md +37 -2
- data/Gemfile +2 -2
- data/README.md +10 -1
- data/Rakefile +43 -7
- data/Upgrade.md +45 -0
- data/features/.nav +1 -0
- data/features/cassettes/automatic_re_recording.feature +19 -17
- data/features/cassettes/dynamic_erb.feature +32 -28
- data/features/cassettes/exclusive.feature +28 -24
- data/features/cassettes/format.feature +213 -31
- data/features/cassettes/update_content_length_header.feature +20 -18
- data/features/configuration/filter_sensitive_data.feature +4 -4
- data/features/configuration/hooks.feature +27 -23
- data/features/http_libraries/em_http_request.feature +79 -75
- data/features/record_modes/all.feature +14 -14
- data/features/record_modes/new_episodes.feature +15 -15
- data/features/record_modes/none.feature +15 -15
- data/features/record_modes/once.feature +15 -15
- data/features/request_matching/body.feature +25 -23
- data/features/request_matching/custom_matcher.feature +25 -23
- data/features/request_matching/headers.feature +32 -36
- data/features/request_matching/host.feature +27 -25
- data/features/request_matching/identical_request_sequence.feature +27 -25
- data/features/request_matching/method.feature +27 -25
- data/features/request_matching/path.feature +27 -25
- data/features/request_matching/playback_repeats.feature +27 -25
- data/features/request_matching/uri.feature +27 -25
- data/features/request_matching/uri_without_param.feature +28 -26
- data/features/step_definitions/cli_steps.rb +71 -17
- data/features/support/env.rb +3 -1
- data/features/support/http_lib_filters.rb +6 -3
- data/features/support/vcr_cucumber_helpers.rb +4 -2
- data/lib/vcr.rb +6 -2
- data/lib/vcr/cassette.rb +75 -51
- data/lib/vcr/cassette/migrator.rb +111 -0
- data/lib/vcr/cassette/serializers.rb +35 -0
- data/lib/vcr/cassette/serializers/json.rb +23 -0
- data/lib/vcr/cassette/serializers/psych.rb +24 -0
- data/lib/vcr/cassette/serializers/syck.rb +35 -0
- data/lib/vcr/cassette/serializers/yaml.rb +24 -0
- data/lib/vcr/configuration.rb +6 -1
- data/lib/vcr/errors.rb +1 -1
- data/lib/vcr/library_hooks/excon.rb +1 -7
- data/lib/vcr/library_hooks/typhoeus.rb +6 -22
- data/lib/vcr/library_hooks/webmock.rb +1 -1
- data/lib/vcr/middleware/faraday.rb +1 -1
- data/lib/vcr/request_matcher_registry.rb +43 -30
- data/lib/vcr/structs.rb +209 -0
- data/lib/vcr/tasks/vcr.rake +9 -0
- data/lib/vcr/version.rb +1 -1
- data/spec/fixtures/cassette_spec/1_x_cassette.yml +110 -0
- data/spec/fixtures/cassette_spec/example.yml +79 -78
- data/spec/fixtures/cassette_spec/with_localhost_requests.yml +79 -77
- data/spec/fixtures/fake_example.com_responses.yml +78 -76
- data/spec/fixtures/match_requests_on.yml +147 -145
- data/spec/monkey_patches.rb +5 -5
- data/spec/support/http_library_adapters.rb +48 -0
- data/spec/support/shared_example_groups/hook_into_http_library.rb +53 -20
- data/spec/support/sinatra_app.rb +12 -0
- data/spec/vcr/cassette/http_interaction_list_spec.rb +1 -1
- data/spec/vcr/cassette/migrator_spec.rb +183 -0
- data/spec/vcr/cassette/serializers_spec.rb +122 -0
- data/spec/vcr/cassette_spec.rb +147 -83
- data/spec/vcr/configuration_spec.rb +11 -1
- data/spec/vcr/library_hooks/typhoeus_spec.rb +3 -3
- data/spec/vcr/library_hooks/webmock_spec.rb +7 -1
- data/spec/vcr/request_ignorer_spec.rb +1 -1
- data/spec/vcr/request_matcher_registry_spec.rb +46 -4
- data/spec/vcr/structs_spec.rb +309 -0
- data/spec/vcr_spec.rb +7 -0
- data/vcr.gemspec +9 -12
- metadata +75 -61
- data/lib/vcr/structs/http_interaction.rb +0 -58
- data/lib/vcr/structs/normalizers/body.rb +0 -24
- data/lib/vcr/structs/normalizers/header.rb +0 -64
- data/lib/vcr/structs/normalizers/status_message.rb +0 -17
- data/lib/vcr/structs/normalizers/uri.rb +0 -34
- data/lib/vcr/structs/request.rb +0 -13
- data/lib/vcr/structs/response.rb +0 -13
- data/lib/vcr/structs/response_status.rb +0 -5
- data/lib/vcr/util/yaml.rb +0 -11
- data/spec/support/shared_example_groups/normalizers.rb +0 -94
- data/spec/vcr/structs/http_interaction_spec.rb +0 -89
- data/spec/vcr/structs/request_spec.rb +0 -39
- data/spec/vcr/structs/response_spec.rb +0 -44
- data/spec/vcr/structs/response_status_spec.rb +0 -9
data/.gitignore
CHANGED
data/.travis.yml
CHANGED
data/CHANGELOG.md
CHANGED
@@ -1,12 +1,47 @@
|
|
1
1
|
## In git
|
2
2
|
|
3
|
-
[Full Changelog](http://github.com/myronmarston/vcr/compare/v2.0.0.
|
3
|
+
[Full Changelog](http://github.com/myronmarston/vcr/compare/v2.0.0.beta2...master)
|
4
|
+
|
5
|
+
## 2.0.0 Beta 2 (November 6, 2011)
|
6
|
+
|
7
|
+
[Full Changelog](http://github.com/myronmarston/vcr/compare/v2.0.0.beta1...v2.0.0.beta2)
|
8
|
+
|
9
|
+
* Update to (and require) Typhoeus 0.3.2.
|
10
|
+
* Fix a bug with `VCR.request_matchers.uri_without_param(:some_param)`
|
11
|
+
so that it properly handles URIs that have no parameters. Thanks to
|
12
|
+
[Sathya Sekaran](https://github.com/sfsekaran) for this fix.
|
13
|
+
* The cassette format has changed significantly:
|
14
|
+
* The HTTPInteractions are no longer normalized in a lossy fashion.
|
15
|
+
VCR 1.x converted all HTTP header keys to lowercase. VCR 2.0 no
|
16
|
+
longer does this because it is impossible to know what the original
|
17
|
+
casing was (i.e. given `etag`, was it originally `etag`, `ETag` or
|
18
|
+
`Etag`?). Also, some HTTP libraries add particular request headers
|
19
|
+
to every request, and these used to be ignored. The aren't anymore.
|
20
|
+
* The ruby struct objects are not directly serialized anymore.
|
21
|
+
Instead, only primitives (hashes, arrays, strings, integers) are
|
22
|
+
serialized. This allows swappable serializers and will allow other
|
23
|
+
tools to read and use a VCR cassette.
|
24
|
+
* Add new serializer API. VCR ships with YAML, Syck, Psych and JSON
|
25
|
+
serializers, and it is very simple to implement your own. The
|
26
|
+
serializer can be configured on a per-cassette basis.
|
27
|
+
* New `vcr:migrate_cassettes DIR=path/to/cassettes` rake task assists
|
28
|
+
with upgrading from VCR 1.x to 2.0.
|
29
|
+
* Cassettes now contain a `recorded_with` attribute. This should
|
30
|
+
allow the cassette structure to be updated more easily in the future
|
31
|
+
as the version number provides a means for easily migrating
|
32
|
+
cassettes.
|
33
|
+
* Add `recorded_at` to data serialized with an HTTPInteraction. This
|
34
|
+
allows the `:re_record_interval` cassette option to work more
|
35
|
+
accurately and no longer rely on the file modification time.
|
36
|
+
|
37
|
+
Note that VCR 1.x cassettes cannot be used with VCR 2.0. See the
|
38
|
+
upgrade notes for more info.
|
4
39
|
|
5
40
|
## 2.0.0 Beta 1 (October 8, 2011)
|
6
41
|
|
7
42
|
[Full Changelog](http://github.com/myronmarston/vcr/compare/v1.11.3...v2.0.0.beta1)
|
8
43
|
|
9
|
-
###
|
44
|
+
### Changed
|
10
45
|
|
11
46
|
* Previously, the last matching response in a cassette would
|
12
47
|
repeatedly playback if the same request kept being made. This is
|
data/Gemfile
CHANGED
data/README.md
CHANGED
@@ -135,6 +135,7 @@ If you find VCR useful, please recommend me on [working with rails](http://worki
|
|
135
135
|
Thanks also to the following people who have contributed patches or helpful suggestions:
|
136
136
|
|
137
137
|
* [Aaron Brethorst](http://github.com/aaronbrethorst)
|
138
|
+
* [Avdi Grimm](https://github.com/avdi)
|
138
139
|
* [Bartosz Blimke](http://github.com/bblimke)
|
139
140
|
* [Ben Hutton](http://github.com/benhutton)
|
140
141
|
* [Bradley Isotope](https://github.com/bradleyisotope)
|
@@ -143,8 +144,16 @@ Thanks also to the following people who have contributed patches or helpful sugg
|
|
143
144
|
* [Karl Baum](https://github.com/kbaum)
|
144
145
|
* [Nathaniel Bibler](https://github.com/nbibler)
|
145
146
|
* [Oliver Searle-Barnes](https://github.com/opsb)
|
147
|
+
* [Sathya Sekaran](https://github.com/sfsekaran)
|
146
148
|
* [Wesley Beary](https://github.com/geemus)
|
147
|
-
|
149
|
+
|
150
|
+
## Similar Libraries
|
151
|
+
|
152
|
+
* [Betamax](https://github.com/robfletcher/betamax) (Groovy)
|
153
|
+
* [Ephemeral Response](https://github.com/sandro/ephemeral_response) (Ruby)
|
154
|
+
* [Mimic](https://github.com/acoulton/mimic) (PHP/Kohana)
|
155
|
+
* [NetRecorder](https://github.com/chrisyoung/netrecorder) (Ruby)
|
156
|
+
* [Stale Fish](https://github.com/jsmestad/stale_fish) (Ruby)
|
148
157
|
|
149
158
|
## Copyright
|
150
159
|
|
data/Rakefile
CHANGED
@@ -15,10 +15,6 @@ RSpec::Core::RakeTask.new(:spec) do |t|
|
|
15
15
|
# we require spec_helper so we don't get an RSpec warning about
|
16
16
|
# examples being defined before configuration.
|
17
17
|
t.ruby_opts = "-w -I./spec -r./spec/capture_warnings -rspec_helper"
|
18
|
-
|
19
|
-
# I'm not sure why, but bundler seems to silence warnings...
|
20
|
-
t.skip_bundler = true
|
21
|
-
|
22
18
|
t.rspec_opts = %w[--format progress] if (ENV['FULL_BUILD'] || !using_git)
|
23
19
|
end
|
24
20
|
|
@@ -51,8 +47,6 @@ namespace :ci do
|
|
51
47
|
# we require spec_helper so we don't get an RSpec warning about
|
52
48
|
# examples being defined before configuration.
|
53
49
|
t.ruby_opts = "-w -I./spec -r./spec/capture_warnings -rspec_helper"
|
54
|
-
# I'm not sure why, but bundler seems to silence warnings...
|
55
|
-
t.skip_bundler = true
|
56
50
|
t.rspec_opts = %w[--format progress --backtrace]
|
57
51
|
end
|
58
52
|
|
@@ -78,7 +72,7 @@ end
|
|
78
72
|
|
79
73
|
desc "Push cukes to relishapp using the relish-client-gem"
|
80
74
|
task :relish do
|
81
|
-
%w[ README.md CHANGELOG.md LICENSE ].each do |file|
|
75
|
+
%w[ README.md CHANGELOG.md Upgrade.md LICENSE ].each do |file|
|
82
76
|
ensure_relish_doc_symlinked(file)
|
83
77
|
end
|
84
78
|
|
@@ -100,3 +94,45 @@ task :release => [:require_ruby_18, :prep_relish_release, :relish]
|
|
100
94
|
# For gem-test: http://gem-testers.org/
|
101
95
|
task :test => :spec
|
102
96
|
|
97
|
+
load './lib/vcr/tasks/vcr.rake'
|
98
|
+
namespace :vcr do
|
99
|
+
task :reset_spec_cassettes do
|
100
|
+
ENV['DIR'] = 'spec/fixtures'
|
101
|
+
def VCR.version; "2.0.0"; end
|
102
|
+
sh "git checkout v2.0.0.beta1 -- spec/fixtures"
|
103
|
+
end
|
104
|
+
|
105
|
+
task :migrate_cassettes => :reset_spec_cassettes
|
106
|
+
end
|
107
|
+
|
108
|
+
desc "Migrate cucumber cassettes"
|
109
|
+
task :migrate_cucumber_cassettes do
|
110
|
+
sh "git checkout cb3559d6ffcb36cb823ae96a677e380e5b86ed80 -- features"
|
111
|
+
require 'vcr/cassette/migrator'
|
112
|
+
Dir["features/**/*.feature"].each do |feature_file|
|
113
|
+
puts " - Migrating #{feature_file}"
|
114
|
+
contents = File.read(feature_file)
|
115
|
+
|
116
|
+
# http://rubular.com/r/gjzkoaYX2O
|
117
|
+
contents.scan(/:\n^\s+"""\n([\s\S]+?)"""/).each do |captures|
|
118
|
+
capture = captures.first
|
119
|
+
indentation = capture[/^ +/]
|
120
|
+
cassette_yml = capture.gsub(/^#{indentation}/, '')
|
121
|
+
new_yml = nil
|
122
|
+
|
123
|
+
Dir.mktmpdir do |dir|
|
124
|
+
file_name = "#{dir}/cassette.yml"
|
125
|
+
File.open(file_name, 'w') { |f| f.write(cassette_yml) }
|
126
|
+
VCR::Cassette::Migrator.new(dir, StringIO.new).migrate!
|
127
|
+
new_yml = File.read(file_name)
|
128
|
+
end
|
129
|
+
|
130
|
+
new_yml.gsub!(/^/, indentation)
|
131
|
+
new_yml << indentation
|
132
|
+
contents.gsub!(capture, new_yml)
|
133
|
+
end
|
134
|
+
|
135
|
+
File.open(feature_file, 'w') { |f| f.write(contents) }
|
136
|
+
end
|
137
|
+
end
|
138
|
+
|
data/Upgrade.md
ADDED
@@ -0,0 +1,45 @@
|
|
1
|
+
See the [Changelog](changelog) for a complete list of changes from VCR
|
2
|
+
1.x to 2.0. This file simply lists the most pertinent ones to upgrading.
|
3
|
+
|
4
|
+
## Configuration Changes
|
5
|
+
|
6
|
+
In VCR 1.x, your configuration block would be something like this:
|
7
|
+
|
8
|
+
``` ruby
|
9
|
+
VCR.config do |c|
|
10
|
+
c.cassette_library_dir = 'cassettes'
|
11
|
+
c.stub_with :fakeweb, :typhoeus
|
12
|
+
end
|
13
|
+
```
|
14
|
+
|
15
|
+
This will continue to work in VCR 2.0 but will generate deprecation
|
16
|
+
warnings. Instead, you should change this to:
|
17
|
+
|
18
|
+
``` ruby
|
19
|
+
VCR.configure do |c|
|
20
|
+
c.cassette_library_dir = 'cassettes'
|
21
|
+
c.hook_into :fakeweb, :typhoeus
|
22
|
+
end
|
23
|
+
```
|
24
|
+
|
25
|
+
## New Cassette Format
|
26
|
+
|
27
|
+
The cassette format has changed between VCR 1.x and VCR 2.0.
|
28
|
+
VCR 1.x cassettes cannot be used with VCR 2.0.
|
29
|
+
|
30
|
+
The easiest way to upgrade is to simply delete your cassettes and
|
31
|
+
re-record all of them. VCR also provides a rake task that attempts
|
32
|
+
to upgrade your 1.x cassettes to the new 2.0 format. To use it, add
|
33
|
+
the following line to your Rakefile:
|
34
|
+
|
35
|
+
``` ruby
|
36
|
+
load 'vcr/tasks/vcr.rake'
|
37
|
+
```
|
38
|
+
|
39
|
+
Then run `rake vcr:migrate_cassettes DIR=path/to/your/cassettes/directory` to
|
40
|
+
upgrade your cassettes. Note that this rake task may be unable to
|
41
|
+
upgrade some cassettes that make extensive use of ERB. In addition, now
|
42
|
+
that VCR 2.0 does less normalization then before, it may not be able to
|
43
|
+
migrate the cassette perfectly. It's recommended that you delete and
|
44
|
+
re-record your cassettes if you are able.
|
45
|
+
|
data/features/.nav
CHANGED
@@ -6,29 +6,31 @@ Feature: Automatic Re-recording
|
|
6
6
|
|
7
7
|
The value provided should be an interval (expressed in seconds) that
|
8
8
|
determines how often VCR will re-record the cassette. When a cassette
|
9
|
-
is used, VCR checks the
|
10
|
-
|
11
|
-
re-recorded.
|
9
|
+
is used, VCR checks the earliest `recorded_at` timestamp in the cassette;
|
10
|
+
if more time than the interval has passed since that timestamp,
|
11
|
+
VCR will use the `:all` record mode to cause it be re-recorded.
|
12
12
|
|
13
13
|
Background:
|
14
14
|
Given a previously recorded cassette file "cassettes/example.yml" with:
|
15
15
|
"""
|
16
|
-
---
|
17
|
-
|
18
|
-
|
19
|
-
method:
|
16
|
+
---
|
17
|
+
http_interactions:
|
18
|
+
- request:
|
19
|
+
method: get
|
20
20
|
uri: http://localhost:7777/
|
21
|
-
body:
|
22
|
-
headers:
|
23
|
-
response:
|
24
|
-
status:
|
21
|
+
body: ''
|
22
|
+
headers: {}
|
23
|
+
response:
|
24
|
+
status:
|
25
25
|
code: 200
|
26
26
|
message: OK
|
27
|
-
headers:
|
28
|
-
|
29
|
-
-
|
27
|
+
headers:
|
28
|
+
Content-Length:
|
29
|
+
- '12'
|
30
30
|
body: Old Response
|
31
|
-
http_version:
|
31
|
+
http_version: '1.1'
|
32
|
+
recorded_at: Tue, 01 Nov 2011 04:58:44 GMT
|
33
|
+
recorded_with: VCR 2.0.0
|
32
34
|
"""
|
33
35
|
And a file named "re_record.rb" with:
|
34
36
|
"""ruby
|
@@ -49,7 +51,7 @@ Feature: Automatic Re-recording
|
|
49
51
|
"""
|
50
52
|
|
51
53
|
Scenario: Cassette is not re-recorded when not enough time has passed
|
52
|
-
Given
|
54
|
+
Given it is Tue, 07 Nov 2011
|
53
55
|
When I run `ruby re_record.rb`
|
54
56
|
Then the output should contain "Old Response"
|
55
57
|
But the output should not contain "New Response"
|
@@ -57,7 +59,7 @@ Feature: Automatic Re-recording
|
|
57
59
|
But the file "cassettes/example.yml" should not contain "body: New Response"
|
58
60
|
|
59
61
|
Scenario: Cassette is re-recorded when enough time has passed
|
60
|
-
Given
|
62
|
+
Given it is Tue, 09 Nov 2011
|
61
63
|
When I run `ruby re_record.rb`
|
62
64
|
Then the output should contain "New Response"
|
63
65
|
But the output should not contain "Old Response"
|
@@ -12,24 +12,26 @@ Feature: Dynamic ERB cassettes
|
|
12
12
|
Scenario: Enable dynamic ERB cassette evalutation using :erb => true
|
13
13
|
Given a previously recorded cassette file "cassettes/dynamic.yml" with:
|
14
14
|
"""
|
15
|
-
---
|
16
|
-
|
17
|
-
|
18
|
-
method:
|
19
|
-
uri: http://example.com
|
20
|
-
body:
|
21
|
-
headers:
|
22
|
-
response:
|
23
|
-
status:
|
15
|
+
---
|
16
|
+
http_interactions:
|
17
|
+
- request:
|
18
|
+
method: get
|
19
|
+
uri: http://example.com/foo?a=<%= 'b' * 3 %>
|
20
|
+
body: ''
|
21
|
+
headers: {}
|
22
|
+
response:
|
23
|
+
status:
|
24
24
|
code: 200
|
25
25
|
message: OK
|
26
|
-
headers:
|
27
|
-
|
26
|
+
headers:
|
27
|
+
Content-Type:
|
28
28
|
- text/html;charset=utf-8
|
29
|
-
|
30
|
-
-
|
29
|
+
Content-Length:
|
30
|
+
- '9'
|
31
31
|
body: Hello <%= 'bar'.next %>
|
32
|
-
http_version:
|
32
|
+
http_version: '1.1'
|
33
|
+
recorded_at: Tue, 01 Nov 2011 04:58:44 GMT
|
34
|
+
recorded_with: VCR 2.0.0
|
33
35
|
"""
|
34
36
|
And a file named "dynamic_erb_example.rb" with:
|
35
37
|
"""ruby
|
@@ -51,24 +53,26 @@ Feature: Dynamic ERB cassettes
|
|
51
53
|
Scenario: Pass arguments to the ERB using :erb => { ... }
|
52
54
|
Given a previously recorded cassette file "cassettes/dynamic.yml" with:
|
53
55
|
"""
|
54
|
-
---
|
55
|
-
|
56
|
-
|
57
|
-
method:
|
58
|
-
uri: http://example.com
|
59
|
-
body:
|
60
|
-
headers:
|
61
|
-
response:
|
62
|
-
status:
|
56
|
+
---
|
57
|
+
http_interactions:
|
58
|
+
- request:
|
59
|
+
method: get
|
60
|
+
uri: http://example.com/foo?a=<%= arg1 %>
|
61
|
+
body: ''
|
62
|
+
headers: {}
|
63
|
+
response:
|
64
|
+
status:
|
63
65
|
code: 200
|
64
66
|
message: OK
|
65
|
-
headers:
|
66
|
-
|
67
|
+
headers:
|
68
|
+
Content-Type:
|
67
69
|
- text/html;charset=utf-8
|
68
|
-
|
69
|
-
-
|
70
|
+
Content-Length:
|
71
|
+
- '9'
|
70
72
|
body: Hello <%= arg2 %>
|
71
|
-
http_version:
|
73
|
+
http_version: '1.1'
|
74
|
+
recorded_at: Tue, 01 Nov 2011 04:58:44 GMT
|
75
|
+
recorded_with: VCR 2.0.0
|
72
76
|
"""
|
73
77
|
And a file named "dynamic_erb_example.rb" with:
|
74
78
|
"""ruby
|
@@ -17,41 +17,45 @@ Feature: exclusive cassette
|
|
17
17
|
Background:
|
18
18
|
Given a previously recorded cassette file "cassettes/outer.yml" with:
|
19
19
|
"""
|
20
|
-
---
|
21
|
-
|
22
|
-
|
23
|
-
method:
|
20
|
+
---
|
21
|
+
http_interactions:
|
22
|
+
- request:
|
23
|
+
method: get
|
24
24
|
uri: http://localhost:7777/outer
|
25
|
-
body:
|
26
|
-
headers:
|
27
|
-
response:
|
28
|
-
status:
|
25
|
+
body: ''
|
26
|
+
headers: {}
|
27
|
+
response:
|
28
|
+
status:
|
29
29
|
code: 200
|
30
30
|
message: OK
|
31
|
-
headers:
|
32
|
-
|
33
|
-
-
|
31
|
+
headers:
|
32
|
+
Content-Length:
|
33
|
+
- '18'
|
34
34
|
body: Old outer response
|
35
|
-
http_version:
|
35
|
+
http_version: '1.1'
|
36
|
+
recorded_at: Tue, 01 Nov 2011 04:58:44 GMT
|
37
|
+
recorded_with: VCR 2.0.0
|
36
38
|
"""
|
37
39
|
And a previously recorded cassette file "cassettes/inner.yml" with:
|
38
40
|
"""
|
39
|
-
---
|
40
|
-
|
41
|
-
|
42
|
-
method:
|
41
|
+
---
|
42
|
+
http_interactions:
|
43
|
+
- request:
|
44
|
+
method: get
|
43
45
|
uri: http://localhost:7777/inner
|
44
|
-
body:
|
45
|
-
headers:
|
46
|
-
response:
|
47
|
-
status:
|
46
|
+
body: ''
|
47
|
+
headers: {}
|
48
|
+
response:
|
49
|
+
status:
|
48
50
|
code: 200
|
49
51
|
message: OK
|
50
|
-
headers:
|
51
|
-
|
52
|
-
-
|
52
|
+
headers:
|
53
|
+
Content-Length:
|
54
|
+
- '18'
|
53
55
|
body: Old inner response
|
54
|
-
http_version:
|
56
|
+
http_version: '1.1'
|
57
|
+
recorded_at: Tue, 01 Nov 2011 04:58:44 GMT
|
58
|
+
recorded_with: VCR 2.0.0
|
55
59
|
"""
|
56
60
|
And a file named "setup.rb" with:
|
57
61
|
"""ruby
|