shotgrid_api_ruby 0.2.0.5 → 0.2.0.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (187) hide show
  1. checksums.yaml +4 -4
  2. data/.github/workflows/test_and_publish.yml +3 -3
  3. data/.github/workflows/test_only.yml +7 -5
  4. data/.ruby-version +1 -1
  5. data/CHANGELOG.md +6 -0
  6. data/Gemfile +12 -0
  7. data/Gemfile.lock +101 -85
  8. data/bin/prettirun +1 -1
  9. data/docs/ShotgridApiRuby/Auth/Validator.html +4 -4
  10. data/docs/ShotgridApiRuby/Auth.html +4 -4
  11. data/docs/ShotgridApiRuby/Client.html +4 -4
  12. data/docs/ShotgridApiRuby/Entities/Params/TooComplexFiltersError.html +4 -4
  13. data/docs/ShotgridApiRuby/Entities/Params.html +4 -4
  14. data/docs/ShotgridApiRuby/Entities/Schema.html +4 -4
  15. data/docs/ShotgridApiRuby/Entities/Summarize/Summary.html +8 -8
  16. data/docs/ShotgridApiRuby/Entities/Summarize.html +4 -4
  17. data/docs/ShotgridApiRuby/Entities.html +4 -4
  18. data/docs/ShotgridApiRuby/Entity.html +12 -12
  19. data/docs/ShotgridApiRuby/Preferences.html +4 -4
  20. data/docs/ShotgridApiRuby/ServerInfo.html +4 -4
  21. data/docs/ShotgridApiRuby/ShotgridCallError.html +4 -4
  22. data/docs/ShotgridApiRuby/Types.html +4 -4
  23. data/docs/ShotgridApiRuby.html +5 -5
  24. data/docs/_index.html +5 -5
  25. data/docs/file.README.html +4 -4
  26. data/docs/frames.html +1 -1
  27. data/docs/index.html +4 -4
  28. data/docs/top-level-namespace.html +4 -4
  29. data/lib/shotgrid_api_ruby/version.rb +1 -1
  30. data/shotgrid_api_ruby.gemspec +0 -9
  31. data/sorbet/rbi/gems/activesupport@7.0.4.2.rbi +18676 -0
  32. data/sorbet/rbi/gems/ast@2.4.2.rbi +533 -3
  33. data/sorbet/rbi/gems/backport@1.2.0.rbi +518 -4
  34. data/sorbet/rbi/gems/benchmark@0.2.1.rbi +588 -0
  35. data/sorbet/rbi/gems/bundler-audit@0.9.1.rbi +308 -0
  36. data/sorbet/rbi/gems/byebug@11.1.3.rbi +2065 -28
  37. data/sorbet/rbi/gems/childprocess@4.1.0.rbi +397 -4
  38. data/sorbet/rbi/gems/coderay@1.1.3.rbi +2425 -4
  39. data/sorbet/rbi/gems/concurrent-ruby@1.2.0.rbi +11570 -0
  40. data/sorbet/rbi/gems/diff-lcs@1.5.0.rbi +1083 -0
  41. data/sorbet/rbi/gems/docile@1.4.0.rbi +335 -13
  42. data/sorbet/rbi/gems/dotenv@2.8.1.rbi +234 -0
  43. data/sorbet/rbi/gems/e2mmap@0.1.0.rbi +4 -4
  44. data/sorbet/rbi/gems/faker@3.1.0.rbi +13380 -0
  45. data/sorbet/rbi/gems/faraday-em_http@1.0.0.rbi +167 -11
  46. data/sorbet/rbi/gems/faraday-em_synchrony@1.0.0.rbi +94 -11
  47. data/sorbet/rbi/gems/faraday-excon@1.1.0.rbi +105 -11
  48. data/sorbet/rbi/gems/faraday-httpclient@1.0.1.rbi +118 -11
  49. data/sorbet/rbi/gems/faraday-multipart@1.0.4.rbi +273 -0
  50. data/sorbet/rbi/gems/faraday-net_http@1.0.1.rbi +106 -11
  51. data/sorbet/rbi/gems/faraday-net_http_persistent@1.2.0.rbi +92 -11
  52. data/sorbet/rbi/gems/faraday-patron@1.0.0.rbi +97 -11
  53. data/sorbet/rbi/gems/faraday-rack@1.0.0.rbi +106 -11
  54. data/sorbet/rbi/gems/faraday-retry@1.0.3.rbi +227 -0
  55. data/sorbet/rbi/gems/faraday@1.10.3.rbi +2743 -0
  56. data/sorbet/rbi/gems/ffi@1.15.5.rbi +8 -0
  57. data/sorbet/rbi/gems/formatador@1.1.0.rbi +8 -0
  58. data/sorbet/rbi/gems/guard-compat@1.2.1.rbi +62 -4
  59. data/sorbet/rbi/gems/guard-rspec@4.7.3.rbi +558 -4
  60. data/sorbet/rbi/gems/guard@2.18.0.rbi +4 -4
  61. data/sorbet/rbi/gems/haml@6.1.1.rbi +1588 -0
  62. data/sorbet/rbi/gems/i18n@1.12.0.rbi +2296 -0
  63. data/sorbet/rbi/gems/iniparse@1.5.0.rbi +893 -4
  64. data/sorbet/rbi/gems/jaro_winkler@1.5.4.rbi +15 -4
  65. data/sorbet/rbi/gems/json@2.6.3.rbi +1533 -0
  66. data/sorbet/rbi/gems/kramdown-parser-gfm@1.1.0.rbi +129 -4
  67. data/sorbet/rbi/gems/kramdown@2.4.0.rbi +3271 -0
  68. data/sorbet/rbi/gems/listen@3.8.0.rbi +1181 -0
  69. data/sorbet/rbi/gems/lumberjack@1.2.8.rbi +4 -4
  70. data/sorbet/rbi/gems/method_source@1.0.0.rbi +202 -2
  71. data/sorbet/rbi/gems/minitest@5.17.0.rbi +1457 -0
  72. data/sorbet/rbi/gems/multipart-post@2.3.0.rbi +233 -0
  73. data/sorbet/rbi/gems/nenv@0.3.0.rbi +4 -4
  74. data/sorbet/rbi/gems/netrc@0.11.0.rbi +158 -0
  75. data/sorbet/rbi/gems/nokogiri@1.14.0.rbi +7250 -0
  76. data/sorbet/rbi/gems/notiffany@0.1.3.rbi +4 -4
  77. data/sorbet/rbi/gems/overcommit@0.60.0.rbi +2399 -0
  78. data/sorbet/rbi/gems/parallel@1.22.1.rbi +277 -0
  79. data/sorbet/rbi/gems/parser@3.2.0.0.rbi +6964 -0
  80. data/sorbet/rbi/gems/prettier@3.2.2.rbi +22 -0
  81. data/sorbet/rbi/gems/prettier_print@1.2.0.rbi +8 -0
  82. data/sorbet/rbi/gems/pry-byebug@3.10.1.rbi +1171 -0
  83. data/sorbet/rbi/gems/pry@0.14.2.rbi +10081 -0
  84. data/sorbet/rbi/gems/racc@1.6.2.rbi +154 -0
  85. data/sorbet/rbi/gems/rainbow@3.1.1.rbi +408 -0
  86. data/sorbet/rbi/gems/rake@13.0.6.rbi +2248 -13
  87. data/sorbet/rbi/gems/rb-fsevent@0.11.2.rbi +8 -0
  88. data/sorbet/rbi/gems/rb-inotify@0.10.1.rbi +4 -4
  89. data/sorbet/rbi/gems/rbi@0.0.16.rbi +3008 -0
  90. data/sorbet/rbi/gems/rbs@2.8.4.rbi +8 -0
  91. data/sorbet/rbi/gems/regexp_parser@2.6.2.rbi +3481 -0
  92. data/sorbet/rbi/gems/reverse_markdown@2.1.1.rbi +389 -0
  93. data/sorbet/rbi/gems/rexml@3.2.5.rbi +4048 -3
  94. data/sorbet/rbi/gems/rspec-core@3.12.0.rbi +10809 -0
  95. data/sorbet/rbi/gems/rspec-expectations@3.12.2.rbi +8109 -0
  96. data/sorbet/rbi/gems/rspec-mocks@3.12.3.rbi +5308 -0
  97. data/sorbet/rbi/gems/rspec-support@3.12.0.rbi +1620 -0
  98. data/sorbet/rbi/gems/rspec@3.12.0.rbi +91 -0
  99. data/sorbet/rbi/gems/rspec_in_context@1.1.0.3.rbi +387 -15
  100. data/sorbet/rbi/gems/rubocop-ast@1.24.1.rbi +7019 -0
  101. data/sorbet/rbi/gems/rubocop-faker@1.1.0.rbi +102 -4
  102. data/sorbet/rbi/gems/rubocop-performance@1.15.2.rbi +3021 -0
  103. data/sorbet/rbi/gems/rubocop-sorbet@0.6.11.rbi +990 -0
  104. data/sorbet/rbi/gems/rubocop@1.44.1.rbi +54394 -0
  105. data/sorbet/rbi/gems/ruby-progressbar@1.11.0.rbi +1235 -4
  106. data/sorbet/rbi/gems/ruby2_keywords@0.0.5.rbi +4 -4
  107. data/sorbet/rbi/gems/shellany@0.0.1.rbi +4 -4
  108. data/sorbet/rbi/gems/simplecov-html@0.12.3.rbi +135 -5
  109. data/sorbet/rbi/gems/simplecov@0.22.0.rbi +2148 -0
  110. data/sorbet/rbi/gems/simplecov_json_formatter@0.1.4.rbi +8 -0
  111. data/sorbet/rbi/gems/solargraph@0.48.0.rbi +9146 -0
  112. data/sorbet/rbi/gems/spoom@1.1.15.rbi +2383 -0
  113. data/sorbet/rbi/gems/syntax_tree-haml@3.0.0.rbi +8 -0
  114. data/sorbet/rbi/gems/syntax_tree-rbs@0.5.1.rbi +8 -0
  115. data/sorbet/rbi/gems/syntax_tree@5.2.0.rbi +8 -0
  116. data/sorbet/rbi/gems/tapioca@0.10.5.rbi +3226 -0
  117. data/sorbet/rbi/gems/temple@0.10.0.rbi +1722 -0
  118. data/sorbet/rbi/gems/thor@1.2.1.rbi +3956 -0
  119. data/sorbet/rbi/gems/tilt@2.0.11.rbi +745 -0
  120. data/sorbet/rbi/gems/timecop@0.9.6.rbi +368 -0
  121. data/sorbet/rbi/gems/tzinfo@2.0.5.rbi +5914 -0
  122. data/sorbet/rbi/gems/unicode-display_width@2.4.2.rbi +65 -0
  123. data/sorbet/rbi/gems/unparser@0.6.7.rbi +4524 -0
  124. data/sorbet/rbi/gems/vcr@6.1.0.rbi +3020 -0
  125. data/sorbet/rbi/gems/webrick@1.7.0.rbi +2555 -0
  126. data/sorbet/rbi/gems/yard-sorbet@0.8.0.rbi +441 -0
  127. data/sorbet/rbi/gems/yard@0.9.28.rbi +17863 -0
  128. data/sorbet/rbi/gems/zeitwerk@2.6.6.rbi +950 -0
  129. data/yarn.lock +3 -3
  130. metadata +67 -186
  131. data/sorbet/rbi/gems/activesupport@6.1.4.1.rbi +0 -3770
  132. data/sorbet/rbi/gems/benchmark@0.1.1.rbi +0 -65
  133. data/sorbet/rbi/gems/bundler-audit@0.8.0.rbi +0 -8
  134. data/sorbet/rbi/gems/colorize@0.8.1.rbi +0 -39
  135. data/sorbet/rbi/gems/commander@4.6.0.rbi +0 -8
  136. data/sorbet/rbi/gems/concurrent-ruby@1.1.9.rbi +0 -2403
  137. data/sorbet/rbi/gems/diff-lcs@1.4.4.rbi +0 -8
  138. data/sorbet/rbi/gems/dotenv@2.7.6.rbi +0 -88
  139. data/sorbet/rbi/gems/faker@2.19.0.rbi +0 -2513
  140. data/sorbet/rbi/gems/faraday@1.7.0.rbi +0 -783
  141. data/sorbet/rbi/gems/ffi@1.15.3.rbi +0 -8
  142. data/sorbet/rbi/gems/formatador@0.3.0.rbi +0 -8
  143. data/sorbet/rbi/gems/haml@5.2.2.rbi +0 -8
  144. data/sorbet/rbi/gems/highline@2.0.3.rbi +0 -8
  145. data/sorbet/rbi/gems/i18n@1.8.10.rbi +0 -584
  146. data/sorbet/rbi/gems/kramdown@2.3.1.rbi +0 -8
  147. data/sorbet/rbi/gems/listen@3.7.0.rbi +0 -476
  148. data/sorbet/rbi/gems/minitest@5.14.4.rbi +0 -344
  149. data/sorbet/rbi/gems/multipart-post@2.1.1.rbi +0 -69
  150. data/sorbet/rbi/gems/nokogiri@1.12.3.rbi +0 -8
  151. data/sorbet/rbi/gems/overcommit@0.58.0.rbi +0 -8
  152. data/sorbet/rbi/gems/parallel@1.20.1.rbi +0 -8
  153. data/sorbet/rbi/gems/parlour@6.0.1.rbi +0 -1610
  154. data/sorbet/rbi/gems/parser@3.0.2.0.rbi +0 -1731
  155. data/sorbet/rbi/gems/prettier@1.6.1.rbi +0 -8
  156. data/sorbet/rbi/gems/pry-byebug@3.9.0.rbi +0 -461
  157. data/sorbet/rbi/gems/pry@0.13.1.rbi +0 -2553
  158. data/sorbet/rbi/gems/racc@1.5.2.rbi +0 -47
  159. data/sorbet/rbi/gems/rainbow@3.0.0.rbi +0 -153
  160. data/sorbet/rbi/gems/rb-fsevent@0.11.0.rbi +0 -8
  161. data/sorbet/rbi/gems/regexp_parser@2.1.1.rbi +0 -8
  162. data/sorbet/rbi/gems/reverse_markdown@2.0.0.rbi +0 -8
  163. data/sorbet/rbi/gems/rspec-core@3.10.1.rbi +0 -2500
  164. data/sorbet/rbi/gems/rspec-expectations@3.10.1.rbi +0 -1574
  165. data/sorbet/rbi/gems/rspec-mocks@3.10.2.rbi +0 -1462
  166. data/sorbet/rbi/gems/rspec-support@3.10.2.rbi +0 -510
  167. data/sorbet/rbi/gems/rspec@3.10.0.rbi +0 -39
  168. data/sorbet/rbi/gems/rubocop-ast@1.11.0.rbi +0 -8
  169. data/sorbet/rbi/gems/rubocop-performance@1.11.5.rbi +0 -8
  170. data/sorbet/rbi/gems/rubocop-sorbet@0.6.2.rbi +0 -8
  171. data/sorbet/rbi/gems/rubocop@1.20.0.rbi +0 -8
  172. data/sorbet/rbi/gems/simplecov@0.21.2.rbi +0 -577
  173. data/sorbet/rbi/gems/simplecov_json_formatter@0.1.3.rbi +0 -8
  174. data/sorbet/rbi/gems/solargraph@0.43.0.rbi +0 -8
  175. data/sorbet/rbi/gems/spoom@1.1.2.rbi +0 -1204
  176. data/sorbet/rbi/gems/tapioca@0.4.25.rbi +0 -1239
  177. data/sorbet/rbi/gems/temple@0.8.2.rbi +0 -8
  178. data/sorbet/rbi/gems/thor@1.1.0.rbi +0 -838
  179. data/sorbet/rbi/gems/tilt@2.0.10.rbi +0 -8
  180. data/sorbet/rbi/gems/timecop@0.9.4.rbi +0 -82
  181. data/sorbet/rbi/gems/tzinfo@2.0.4.rbi +0 -857
  182. data/sorbet/rbi/gems/unicode-display_width@2.0.0.rbi +0 -8
  183. data/sorbet/rbi/gems/unparser@0.6.0.rbi +0 -8
  184. data/sorbet/rbi/gems/vcr@6.0.0.rbi +0 -782
  185. data/sorbet/rbi/gems/yard-sorbet@0.5.3.rbi +0 -8
  186. data/sorbet/rbi/gems/yard@0.9.26.rbi +0 -8
  187. data/sorbet/rbi/gems/zeitwerk@2.4.2.rbi +0 -173
@@ -0,0 +1,3020 @@
1
+ # typed: true
2
+
3
+ # DO NOT EDIT MANUALLY
4
+ # This is an autogenerated file for types exported from the `vcr` gem.
5
+ # Please instead update this file by running `bin/tapioca gem vcr`.
6
+
7
+ # The main entry point for VCR.
8
+ #
9
+ # @note This module is extended onto itself; thus, the methods listed
10
+ # here as instance methods are available directly off of VCR.
11
+ #
12
+ # source://vcr//lib/vcr/util/logger.rb#1
13
+ module VCR
14
+ include ::VCR::VariableArgsBlockCaller
15
+ include ::VCR::Errors
16
+ extend ::VCR::VariableArgsBlockCaller
17
+ extend ::VCR::Errors
18
+ extend ::VCR
19
+
20
+ # @private
21
+ #
22
+ # source://vcr//lib/vcr.rb#385
23
+ def cassette_persisters; end
24
+
25
+ # @private
26
+ #
27
+ # source://vcr//lib/vcr.rb#380
28
+ def cassette_serializers; end
29
+
30
+ # @return [Enumerable] list of all cassettes currently being used
31
+ #
32
+ # source://vcr//lib/vcr.rb#362
33
+ def cassettes(context = T.unsafe(nil)); end
34
+
35
+ # @deprecated Use #configure instead.
36
+ # @see #configure
37
+ #
38
+ # source://vcr//lib/vcr/deprecations.rb#4
39
+ def config; end
40
+
41
+ # @return [VCR::Configuration] the VCR configuration.
42
+ #
43
+ # source://vcr//lib/vcr.rb#239
44
+ def configuration; end
45
+
46
+ # Used to configure VCR.
47
+ #
48
+ # @example
49
+ # VCR.configure do |c|
50
+ # c.some_config_option = true
51
+ # end
52
+ # @return [void]
53
+ # @yield the configuration block
54
+ # @yieldparam config [VCR::Configuration] the configuration object
55
+ #
56
+ # source://vcr//lib/vcr.rb#234
57
+ def configure; end
58
+
59
+ # Sets up `Before` and `After` cucumber hooks in order to
60
+ # use VCR with particular cucumber tags.
61
+ #
62
+ # @example
63
+ # VCR.cucumber_tags do |t|
64
+ # t.tags "tag1", "tag2"
65
+ # t.tag "@some_other_tag", :record => :new_episodes
66
+ # end
67
+ # @return [void]
68
+ # @see VCR::CucumberTags#tags
69
+ # @yield the cucumber tags configuration block
70
+ # @yieldparam t [VCR::CucumberTags] Cucumber tags config object
71
+ #
72
+ # source://vcr//lib/vcr.rb#256
73
+ def cucumber_tags(&block); end
74
+
75
+ # The currently active cassette.
76
+ #
77
+ # @return [nil, VCR::Cassette] The current cassette or nil if there is
78
+ # no current cassette.
79
+ #
80
+ # source://vcr//lib/vcr.rb#48
81
+ def current_cassette; end
82
+
83
+ # Ejects the current cassette. The cassette will no longer be used.
84
+ # In addition, any newly recorded HTTP interactions will be written to
85
+ # disk.
86
+ #
87
+ # @option options
88
+ # @param options [Hash] Eject options.
89
+ # @return [VCR::Cassette, nil] the ejected cassette if there was one
90
+ #
91
+ # source://vcr//lib/vcr.rb#159
92
+ def eject_cassette(options = T.unsafe(nil)); end
93
+
94
+ # @private
95
+ # @return [Boolean]
96
+ #
97
+ # source://vcr//lib/vcr.rb#408
98
+ def fibers_available?; end
99
+
100
+ # @private
101
+ #
102
+ # source://vcr//lib/vcr.rb#345
103
+ def http_interactions; end
104
+
105
+ # Inserts the named cassette using the given cassette options.
106
+ # New HTTP interactions, if allowed by the cassette's `:record` option, will
107
+ # be recorded to the cassette. The cassette's existing HTTP interactions
108
+ # will be used to stub requests, unless prevented by the cassette's
109
+ # `:record` option.
110
+ #
111
+ # @example
112
+ # VCR.insert_cassette('twitter', :record => :new_episodes)
113
+ #
114
+ # # ...later, after making an HTTP request:
115
+ #
116
+ # VCR.eject_cassette
117
+ # @note If you use this method you _must_ call `eject_cassette` when you
118
+ # are done. It is generally recommended that you use {#use_cassette}
119
+ # unless your code-under-test cannot be run as a block.
120
+ # @option options
121
+ # @option options
122
+ # @option options
123
+ # @option options
124
+ # @option options
125
+ # @option options
126
+ # @option options
127
+ # @option options
128
+ # @option options
129
+ # @option options
130
+ # @option options
131
+ # @option options
132
+ # @option options
133
+ # @option options
134
+ # @option options
135
+ # @param name [#to_s] The name of the cassette. VCR will sanitize
136
+ # this to ensure it is a valid file name.
137
+ # @param options [Hash] The cassette options. The given options will
138
+ # be merged with the configured default_cassette_options.
139
+ # @raise [ArgumentError] when the given cassette is already being used.
140
+ # @raise [VCR::Errors::TurnedOffError] when VCR has been turned off
141
+ # without using the :ignore_cassettes option.
142
+ # @raise [VCR::Errors::MissingERBVariableError] when the `:erb` option
143
+ # is used and the ERB template requires variables that you did not provide.
144
+ # @return [VCR::Cassette] the inserted cassette
145
+ #
146
+ # source://vcr//lib/vcr.rb#132
147
+ def insert_cassette(name, options = T.unsafe(nil)); end
148
+
149
+ # @private
150
+ #
151
+ # source://vcr//lib/vcr.rb#375
152
+ def library_hooks; end
153
+
154
+ # @private
155
+ #
156
+ # source://vcr//lib/vcr.rb#398
157
+ def link_context(from_thread, to_key); end
158
+
159
+ # @private
160
+ # @return [Boolean]
161
+ #
162
+ # source://vcr//lib/vcr.rb#351
163
+ def real_http_connections_allowed?; end
164
+
165
+ # @private
166
+ #
167
+ # source://vcr//lib/vcr.rb#390
168
+ def record_http_interaction(interaction); end
169
+
170
+ # @private
171
+ #
172
+ # source://vcr//lib/vcr.rb#370
173
+ def request_ignorer; end
174
+
175
+ # @return [RequestMatcherRegistry] the request matcher registry
176
+ #
177
+ # source://vcr//lib/vcr.rb#357
178
+ def request_matchers; end
179
+
180
+ # Turns VCR off, so that it no longer handles every HTTP request.
181
+ #
182
+ # @option options
183
+ # @param options [Hash] hash of options
184
+ # @raise [VCR::Errors::CassetteInUseError] if there is currently a cassette in use
185
+ # @raise [ArgumentError] if you pass an invalid option
186
+ # @return [void]
187
+ #
188
+ # source://vcr//lib/vcr.rb#290
189
+ def turn_off!(options = T.unsafe(nil)); end
190
+
191
+ # Turns on VCR, if it has previously been turned off.
192
+ #
193
+ # @return [void]
194
+ # @see #turn_off!
195
+ # @see #turned_off
196
+ # @see #turned_on?
197
+ # @see #turned_on
198
+ #
199
+ # source://vcr//lib/vcr.rb#327
200
+ def turn_on!; end
201
+
202
+ # Turns VCR off for the duration of a block.
203
+ #
204
+ # @param options [Hash] hash of options
205
+ # @raise [VCR::Errors::CassetteInUseError] if there is currently a cassette in use
206
+ # @raise [ArgumentError] if you pass an invalid option
207
+ # @return [void]
208
+ # @see #turned_on
209
+ # @see #turn_off!
210
+ # @see #turn_on!
211
+ # @see #turned_on?
212
+ #
213
+ # source://vcr//lib/vcr.rb#270
214
+ def turned_off(options = T.unsafe(nil)); end
215
+
216
+ # Turns on VCR, for the duration of a block.
217
+ #
218
+ # @param options [Hash] hash of options
219
+ # @return [void]
220
+ # @see #turn_off!
221
+ # @see #turned_off
222
+ # @see #turned_on?
223
+ #
224
+ # source://vcr//lib/vcr.rb#311
225
+ def turned_on(options = T.unsafe(nil)); end
226
+
227
+ # @note Normally VCR is _always_ turned on; it will only be off if you have
228
+ # explicitly turned it off.
229
+ # @return [Boolean] whether or not VCR is turned on
230
+ # @see #turn_on!
231
+ # @see #turn_off!
232
+ # @see #turned_off
233
+ #
234
+ # source://vcr//lib/vcr.rb#337
235
+ def turned_on?; end
236
+
237
+ # @private
238
+ #
239
+ # source://vcr//lib/vcr.rb#403
240
+ def unlink_context(key); end
241
+
242
+ # Inserts a cassette using the given name and options, runs the given
243
+ # block, and ejects the cassette.
244
+ #
245
+ # @example
246
+ # VCR.use_cassette('twitter', :record => :new_episodes) do
247
+ # # make an HTTP request
248
+ # end
249
+ # @option options
250
+ # @option options
251
+ # @option options
252
+ # @option options
253
+ # @option options
254
+ # @option options
255
+ # @option options
256
+ # @option options
257
+ # @option options
258
+ # @option options
259
+ # @option options
260
+ # @option options
261
+ # @option options
262
+ # @option options
263
+ # @option options
264
+ # @param name [#to_s] The name of the cassette. VCR will sanitize
265
+ # this to ensure it is a valid file name.
266
+ # @param options [Hash] The cassette options. The given options will
267
+ # be merged with the configured default_cassette_options.
268
+ # @raise [ArgumentError] when the given cassette is already being used.
269
+ # @raise [VCR::Errors::TurnedOffError] when VCR has been turned off
270
+ # without using the :ignore_cassettes option.
271
+ # @raise [VCR::Errors::MissingERBVariableError] when the `:erb` option
272
+ # is used and the ERB template requires variables that you did not provide.
273
+ # @return [void]
274
+ # @see #insert_cassette
275
+ # @see #eject_cassette
276
+ # @yield Block to run while this cassette is in use.
277
+ # @yieldparam cassette [(optional) VCR::Cassette] the cassette that has
278
+ # been inserted.
279
+ #
280
+ # source://vcr//lib/vcr.rb#184
281
+ def use_cassette(name, options = T.unsafe(nil), &block); end
282
+
283
+ # Inserts multiple cassettes the given names
284
+ #
285
+ # @example
286
+ # cassettes = [
287
+ # { name: 'github' },
288
+ # { name: 'apple', options: { erb: true } }
289
+ # ]
290
+ # VCR.use_cassettes(cassettes) do
291
+ # # make multiple HTTP requests
292
+ # end
293
+ #
294
+ # source://vcr//lib/vcr.rb#213
295
+ def use_cassettes(cassettes, &block); end
296
+
297
+ # @note This string also has singleton methods:
298
+ #
299
+ # * `major` [Integer] The major version.
300
+ # * `minor` [Integer] The minor version.
301
+ # * `patch` [Integer] The patch version.
302
+ # * `parts` [Array<Integer>] List of the version parts.
303
+ # @return [String] the current VCR version.
304
+ #
305
+ # source://vcr//lib/vcr/version.rb#11
306
+ def version; end
307
+
308
+ private
309
+
310
+ # source://vcr//lib/vcr.rb#448
311
+ def context_cassettes; end
312
+
313
+ # source://vcr//lib/vcr.rb#427
314
+ def context_value(name); end
315
+
316
+ # source://vcr//lib/vcr.rb#413
317
+ def current_context; end
318
+
319
+ # source://vcr//lib/vcr.rb#435
320
+ def dup_context(context); end
321
+
322
+ # source://vcr//lib/vcr.rb#417
323
+ def get_context(thread_key, fiber_key = T.unsafe(nil)); end
324
+
325
+ # @return [Boolean]
326
+ #
327
+ # source://vcr//lib/vcr.rb#444
328
+ def ignore_cassettes?; end
329
+
330
+ # source://vcr//lib/vcr.rb#452
331
+ def initialize_fibers; end
332
+
333
+ # source://vcr//lib/vcr.rb#461
334
+ def initialize_ivars; end
335
+
336
+ # source://vcr//lib/vcr.rb#431
337
+ def set_context_value(name, value); end
338
+
339
+ class << self
340
+ # @private
341
+ #
342
+ # source://vcr//lib/vcr/deprecations.rb#10
343
+ def const_missing(const); end
344
+ end
345
+ end
346
+
347
+ # The media VCR uses to store HTTP interactions for later re-use.
348
+ #
349
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#2
350
+ class VCR::Cassette
351
+ include ::VCR::Logger::Mixin
352
+
353
+ # @param name [#to_s] The name of the cassette. VCR will sanitize
354
+ # this to ensure it is a valid file name.
355
+ # @param options [Hash] The cassette options. The given options will
356
+ # be merged with the configured default_cassette_options.
357
+ # @return [Cassette] a new instance of Cassette
358
+ # @see VCR#insert_cassette
359
+ #
360
+ # source://vcr//lib/vcr/cassette.rb#55
361
+ def initialize(name, options = T.unsafe(nil)); end
362
+
363
+ # @return [Boolean, nil] Should outdated interactions be recorded back to file
364
+ #
365
+ # source://vcr//lib/vcr/cassette.rb#47
366
+ def clean_outdated_http_interactions; end
367
+
368
+ # Ejects the current cassette. The cassette will no longer be used.
369
+ # In addition, any newly recorded HTTP interactions will be written to
370
+ # disk.
371
+ #
372
+ # @note This is not intended to be called directly. Use `VCR.eject_cassette` instead.
373
+ # @see VCR#eject_cassette
374
+ #
375
+ # source://vcr//lib/vcr/cassette.rb#75
376
+ def eject(options = T.unsafe(nil)); end
377
+
378
+ # @return [Boolean, Hash] The cassette's ERB option. The file will be treated as an
379
+ # ERB template if this has a truthy value. A hash, if provided, will be used as local
380
+ # variables for the ERB template.
381
+ #
382
+ # source://vcr//lib/vcr/cassette.rb#41
383
+ def erb; end
384
+
385
+ # @note VCR will take care of sanitizing the cassette name to make it a valid file name.
386
+ # @raise [NotImplementedError] if the configured cassette persister
387
+ # does not support resolving file paths.
388
+ # @return [String] The file for this cassette.
389
+ #
390
+ # source://vcr//lib/vcr/cassette.rb#129
391
+ def file; end
392
+
393
+ # @private
394
+ #
395
+ # source://vcr//lib/vcr/cassette.rb#99
396
+ def http_interactions; end
397
+
398
+ # @return [Boolean] false unless wrapped with LinkedCassette
399
+ #
400
+ # source://vcr//lib/vcr/cassette.rb#168
401
+ def linked?; end
402
+
403
+ # @return [Array<Symbol, #call>] List of request matchers. Used to find a response from an
404
+ # existing HTTP interaction to play back.
405
+ #
406
+ # source://vcr//lib/vcr/cassette.rb#36
407
+ def match_requests_on; end
408
+
409
+ # @return [#to_s] The name of the cassette. Used to determine the cassette's file name.
410
+ # @see #file
411
+ #
412
+ # source://vcr//lib/vcr/cassette.rb#21
413
+ def name; end
414
+
415
+ # @private
416
+ #
417
+ # source://vcr//lib/vcr/cassette.rb#121
418
+ def new_recorded_interactions; end
419
+
420
+ # @example
421
+ #
422
+ # VCR.use_cassette("some cassette") do |cassette|
423
+ # Timecop.freeze(cassette.originally_recorded_at || Time.now) do
424
+ # # ...
425
+ # end
426
+ # end
427
+ # @return [Time, nil] The `recorded_at` time of the first HTTP interaction
428
+ # or nil if the cassette has no prior HTTP interactions.
429
+ #
430
+ # source://vcr//lib/vcr/cassette.rb#163
431
+ def originally_recorded_at; end
432
+
433
+ # @return [Integer, nil] How frequently (in seconds) the cassette should be re-recorded.
434
+ #
435
+ # source://vcr//lib/vcr/cassette.rb#44
436
+ def re_record_interval; end
437
+
438
+ # @private
439
+ #
440
+ # source://vcr//lib/vcr/cassette.rb#113
441
+ def record_http_interaction(interaction); end
442
+
443
+ # @return [Symbol] The record mode. Determines whether the cassette records HTTP interactions,
444
+ # plays them back, or does both.
445
+ #
446
+ # source://vcr//lib/vcr/cassette.rb#25
447
+ def record_mode; end
448
+
449
+ # @return [Boolean] The cassette's record_on_error mode. When the code that uses the cassette
450
+ # raises an error (for example a test failure) and record_on_error is set to false, no
451
+ # cassette will be recorded. This is useful when you are TDD'ing an API integration: when
452
+ # an error is raised that often means your request is invalid, so you don't want the cassette
453
+ # to be recorded.
454
+ #
455
+ # source://vcr//lib/vcr/cassette.rb#32
456
+ def record_on_error; end
457
+
458
+ # @return [Boolean] Whether or not the cassette is recording.
459
+ #
460
+ # source://vcr//lib/vcr/cassette.rb#137
461
+ def recording?; end
462
+
463
+ # @private
464
+ #
465
+ # source://vcr//lib/vcr/cassette.rb#84
466
+ def run_failed!; end
467
+
468
+ # @private
469
+ # @return [Boolean]
470
+ #
471
+ # source://vcr//lib/vcr/cassette.rb#89
472
+ def run_failed?; end
473
+
474
+ # @return [Hash] The hash that will be serialized when the cassette is written to disk.
475
+ #
476
+ # source://vcr//lib/vcr/cassette.rb#146
477
+ def serializable_hash; end
478
+
479
+ # @return [Boolean]
480
+ #
481
+ # source://vcr//lib/vcr/cassette.rb#94
482
+ def should_write_recorded_interactions_to_disk?; end
483
+
484
+ # @return [Array<Symbol>] If set, {VCR::Configuration#before_record} and
485
+ # {VCR::Configuration#before_playback} hooks with a corresponding tag will apply.
486
+ #
487
+ # source://vcr//lib/vcr/cassette.rb#51
488
+ def tags; end
489
+
490
+ private
491
+
492
+ # source://vcr//lib/vcr/cassette.rb#174
493
+ def assert_valid_options!; end
494
+
495
+ # source://vcr//lib/vcr/cassette.rb#201
496
+ def assign_tags; end
497
+
498
+ # source://vcr//lib/vcr/cassette.rb#312
499
+ def deserialized_hash; end
500
+
501
+ # source://vcr//lib/vcr/cassette.rb#187
502
+ def extract_options; end
503
+
504
+ # source://vcr//lib/vcr/cassette.rb#288
505
+ def interactions_to_record; end
506
+
507
+ # source://vcr//lib/vcr/cassette.rb#304
508
+ def invoke_hook(type, interactions); end
509
+
510
+ # source://vcr//lib/vcr/cassette.rb#325
511
+ def log_prefix; end
512
+
513
+ # source://vcr//lib/vcr/cassette.rb#270
514
+ def merged_interactions; end
515
+
516
+ # source://vcr//lib/vcr/cassette.rb#209
517
+ def previously_recorded_interactions; end
518
+
519
+ # source://vcr//lib/vcr/cassette.rb#227
520
+ def raise_error_unless_valid_record_mode; end
521
+
522
+ # source://vcr//lib/vcr/cassette.rb#266
523
+ def raw_cassette_bytes; end
524
+
525
+ # source://vcr//lib/vcr/cassette.rb#329
526
+ def request_summary(request); end
527
+
528
+ # @return [Boolean]
529
+ #
530
+ # source://vcr//lib/vcr/cassette.rb#262
531
+ def should_assert_no_unused_interactions?; end
532
+
533
+ # @return [Boolean]
534
+ #
535
+ # source://vcr//lib/vcr/cassette.rb#233
536
+ def should_re_record?(record_mode); end
537
+
538
+ # @return [Boolean]
539
+ #
540
+ # source://vcr//lib/vcr/cassette.rb#258
541
+ def should_remove_matching_existing_interactions?; end
542
+
543
+ # @return [Boolean]
544
+ #
545
+ # source://vcr//lib/vcr/cassette.rb#254
546
+ def should_stub_requests?; end
547
+
548
+ # source://vcr//lib/vcr/cassette.rb#223
549
+ def storage_key; end
550
+
551
+ # source://vcr//lib/vcr/cassette.rb#283
552
+ def up_to_date_interactions(interactions); end
553
+
554
+ # source://vcr//lib/vcr/cassette.rb#296
555
+ def write_recorded_interactions_to_disk; end
556
+
557
+ class << self
558
+ # @private
559
+ #
560
+ # source://vcr//lib/vcr/deprecations.rb#17
561
+ def const_missing(const); end
562
+ end
563
+ end
564
+
565
+ # @private
566
+ #
567
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#6
568
+ class VCR::Cassette::ERBRenderer
569
+ # @return [ERBRenderer] a new instance of ERBRenderer
570
+ #
571
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#7
572
+ def initialize(raw_template, erb, cassette_name = T.unsafe(nil)); end
573
+
574
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#11
575
+ def render; end
576
+
577
+ private
578
+
579
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#52
580
+ def binding_for_variables; end
581
+
582
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#34
583
+ def erb_variables; end
584
+
585
+ # @raise [Errors::MissingERBVariableError]
586
+ #
587
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#21
588
+ def handle_name_error(e); end
589
+
590
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#38
591
+ def template; end
592
+
593
+ # @return [Boolean]
594
+ #
595
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#30
596
+ def use_erb?; end
597
+
598
+ # source://vcr//lib/vcr/cassette/erb_renderer.rb#48
599
+ def variables_object; end
600
+ end
601
+
602
+ # @private
603
+ #
604
+ # source://vcr//lib/vcr/cassette/serializers.rb#49
605
+ module VCR::Cassette::EncodingErrorHandling
606
+ # source://vcr//lib/vcr/cassette/serializers.rb#50
607
+ def handle_encoding_errors; end
608
+ end
609
+
610
+ # @private
611
+ #
612
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#4
613
+ class VCR::Cassette::HTTPInteractionList
614
+ include ::VCR::Logger::Mixin
615
+
616
+ # @return [HTTPInteractionList] a new instance of HTTPInteractionList
617
+ #
618
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#18
619
+ def initialize(interactions, request_matchers, allow_playback_repeats = T.unsafe(nil), parent_list = T.unsafe(nil), log_prefix = T.unsafe(nil)); end
620
+
621
+ # Returns the value of attribute allow_playback_repeats.
622
+ #
623
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#16
624
+ def allow_playback_repeats; end
625
+
626
+ # Checks if there are no unused interactions left.
627
+ #
628
+ # @raise [VCR::Errors::UnusedHTTPInteractionError] if not all interactions were played back.
629
+ #
630
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#65
631
+ def assert_no_unused_interactions!; end
632
+
633
+ # @return [Boolean]
634
+ #
635
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#48
636
+ def has_interaction_matching?(request); end
637
+
638
+ # @return [Boolean]
639
+ #
640
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#54
641
+ def has_used_interaction_matching?(request); end
642
+
643
+ # Returns the value of attribute interactions.
644
+ #
645
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#16
646
+ def interactions; end
647
+
648
+ # Returns the value of attribute parent_list.
649
+ #
650
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#16
651
+ def parent_list; end
652
+
653
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#58
654
+ def remaining_unused_interaction_count; end
655
+
656
+ # Returns the value of attribute request_matchers.
657
+ #
658
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#16
659
+ def request_matchers; end
660
+
661
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#31
662
+ def response_for(request); end
663
+
664
+ private
665
+
666
+ # @return [Boolean] Whether or not there are unused interactions left in the list.
667
+ #
668
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#79
669
+ def has_unused_interactions?; end
670
+
671
+ # @return [Boolean]
672
+ #
673
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#96
674
+ def interaction_matches_request?(request, interaction); end
675
+
676
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#107
677
+ def log_prefix; end
678
+
679
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#87
680
+ def matching_interaction_index_for(request); end
681
+
682
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#91
683
+ def matching_used_interaction_for(request); end
684
+
685
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#83
686
+ def request_summary(request); end
687
+ end
688
+
689
+ # @private
690
+ #
691
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#8
692
+ module VCR::Cassette::HTTPInteractionList::NullList
693
+ extend ::VCR::Cassette::HTTPInteractionList::NullList
694
+
695
+ # @return [Boolean]
696
+ #
697
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#11
698
+ def has_interaction_matching?(*a); end
699
+
700
+ # @return [Boolean]
701
+ #
702
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#12
703
+ def has_used_interaction_matching?(*a); end
704
+
705
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#13
706
+ def remaining_unused_interaction_count(*a); end
707
+
708
+ # source://vcr//lib/vcr/cassette/http_interaction_list.rb#10
709
+ def response_for(*a); end
710
+ end
711
+
712
+ # Keeps track of the cassette persisters in a hash-like object.
713
+ #
714
+ # source://vcr//lib/vcr/cassette/persisters.rb#4
715
+ class VCR::Cassette::Persisters
716
+ # @private
717
+ # @return [Persisters] a new instance of Persisters
718
+ #
719
+ # source://vcr//lib/vcr/cassette/persisters.rb#8
720
+ def initialize; end
721
+
722
+ # Gets the named persister.
723
+ #
724
+ # @param name [Symbol] the name of the persister
725
+ # @raise [ArgumentError] if there is not a persister for the given name
726
+ # @return the named persister
727
+ #
728
+ # source://vcr//lib/vcr/cassette/persisters.rb#17
729
+ def [](name); end
730
+
731
+ # Registers a persister.
732
+ #
733
+ # @param name [Symbol] the name of the persister
734
+ # @param value [#[], #[]=] the persister object. It must implement `[]` and `[]=`.
735
+ #
736
+ # source://vcr//lib/vcr/cassette/persisters.rb#31
737
+ def []=(name, value); end
738
+ end
739
+
740
+ # The only built-in cassette persister. Persists cassettes to the file system.
741
+ #
742
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#7
743
+ module VCR::Cassette::Persisters::FileSystem
744
+ extend ::VCR::Cassette::Persisters::FileSystem
745
+
746
+ # Gets the cassette for the given storage key (file name).
747
+ #
748
+ # @param file_name [String] the file name
749
+ # @return [String] the cassette content
750
+ #
751
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#23
752
+ def [](file_name); end
753
+
754
+ # Sets the cassette for the given storage key (file name).
755
+ #
756
+ # @param file_name [String] the file name
757
+ # @param content [String] the content to store
758
+ #
759
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#33
760
+ def []=(file_name, content); end
761
+
762
+ # @private
763
+ #
764
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#41
765
+ def absolute_path_to_file(file_name); end
766
+
767
+ # @private
768
+ #
769
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#11
770
+ def storage_location; end
771
+
772
+ # @private
773
+ #
774
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#14
775
+ def storage_location=(dir); end
776
+
777
+ private
778
+
779
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#47
780
+ def absolute_path_for(path); end
781
+
782
+ # @return [Boolean]
783
+ #
784
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#63
785
+ def downcase_cassette_names?; end
786
+
787
+ # source://vcr//lib/vcr/cassette/persisters/file_system.rb#51
788
+ def sanitized_file_name_from(file_name); end
789
+ end
790
+
791
+ # Keeps track of the cassette serializers in a hash-like object.
792
+ #
793
+ # source://vcr//lib/vcr/cassette/serializers.rb#4
794
+ class VCR::Cassette::Serializers
795
+ # @private
796
+ # @return [Serializers] a new instance of Serializers
797
+ #
798
+ # source://vcr//lib/vcr/cassette/serializers.rb#12
799
+ def initialize; end
800
+
801
+ # Gets the named serializer.
802
+ #
803
+ # @param name [Symbol] the name of the serializer
804
+ # @raise [ArgumentError] if there is not a serializer for the given name
805
+ # @return the named serializer
806
+ #
807
+ # source://vcr//lib/vcr/cassette/serializers.rb#21
808
+ def [](name); end
809
+
810
+ # Registers a serializer.
811
+ #
812
+ # @param name [Symbol] the name of the serializer
813
+ # @param value [#file_extension, #serialize, #deserialize] the serializer object. It must implement
814
+ # `file_extension()`, `serialize(Hash)` and `deserialize(String)`.
815
+ #
816
+ # source://vcr//lib/vcr/cassette/serializers.rb#39
817
+ def []=(name, value); end
818
+ end
819
+
820
+ # The compressed serializer. This serializer wraps the YAML serializer
821
+ # to write compressed cassettes to disk.
822
+ #
823
+ # Cassettes containing responses with JSON data often compress at greater
824
+ # than 10:1. The tradeoff is that cassettes will not diff nicely or be
825
+ # easily inspectable or editable.
826
+ #
827
+ # @see YAML
828
+ #
829
+ # source://vcr//lib/vcr/cassette/serializers/compressed.rb#15
830
+ module VCR::Cassette::Serializers::Compressed
831
+ extend ::VCR::Cassette::Serializers::Compressed
832
+
833
+ # Deserializes the given compressed cassette data.
834
+ #
835
+ # @param string [String] the compressed YAML cassette data
836
+ # @return [Hash] the deserialized object
837
+ #
838
+ # source://vcr//lib/vcr/cassette/serializers/compressed.rb#38
839
+ def deserialize(string); end
840
+
841
+ # The file extension to use for this serializer.
842
+ #
843
+ # @return [String] "zz"
844
+ #
845
+ # source://vcr//lib/vcr/cassette/serializers/compressed.rb#21
846
+ def file_extension; end
847
+
848
+ # Serializes the given hash using YAML and Zlib.
849
+ #
850
+ # @param hash [Hash] the object to serialize
851
+ # @return [String] the compressed cassette data
852
+ #
853
+ # source://vcr//lib/vcr/cassette/serializers/compressed.rb#29
854
+ def serialize(hash); end
855
+ end
856
+
857
+ # The JSON serializer.
858
+ #
859
+ # @see Psych
860
+ # @see Syck
861
+ # @see YAML
862
+ #
863
+ # source://vcr//lib/vcr/cassette/serializers/json.rb#11
864
+ module VCR::Cassette::Serializers::JSON
865
+ extend ::VCR::Cassette::Serializers::JSON
866
+ extend ::VCR::Cassette::EncodingErrorHandling
867
+ extend ::VCR::Cassette::SyntaxErrorHandling
868
+
869
+ # Deserializes the given string using `JSON`.
870
+ #
871
+ # @param string [String] the JSON string
872
+ # @return [Hash] the deserialized object
873
+ #
874
+ # source://vcr//lib/vcr/cassette/serializers/json.rb#44
875
+ def deserialize(string); end
876
+
877
+ # The file extension to use for this serializer.
878
+ #
879
+ # @return [String] "json"
880
+ #
881
+ # source://vcr//lib/vcr/cassette/serializers/json.rb#26
882
+ def file_extension; end
883
+
884
+ # Serializes the given hash using `JSON`.
885
+ #
886
+ # @param hash [Hash] the object to serialize
887
+ # @return [String] the JSON string
888
+ #
889
+ # source://vcr//lib/vcr/cassette/serializers/json.rb#34
890
+ def serialize(hash); end
891
+ end
892
+
893
+ # @private
894
+ #
895
+ # source://vcr//lib/vcr/cassette/serializers/json.rb#17
896
+ VCR::Cassette::Serializers::JSON::ENCODING_ERRORS = T.let(T.unsafe(nil), Array)
897
+
898
+ # @private
899
+ #
900
+ # source://vcr//lib/vcr/cassette/serializers/json.rb#21
901
+ VCR::Cassette::Serializers::JSON::SYNTAX_ERRORS = T.let(T.unsafe(nil), Array)
902
+
903
+ # The Psych serializer. Psych is the new YAML engine in ruby 1.9.
904
+ #
905
+ # @see JSON
906
+ # @see Syck
907
+ # @see YAML
908
+ #
909
+ # source://vcr//lib/vcr/cassette/serializers/psych.rb#11
910
+ module VCR::Cassette::Serializers::Psych
911
+ extend ::VCR::Cassette::Serializers::Psych
912
+ extend ::VCR::Cassette::EncodingErrorHandling
913
+ extend ::VCR::Cassette::SyntaxErrorHandling
914
+
915
+ # Deserializes the given string using Psych.
916
+ #
917
+ # @param string [String] the YAML string
918
+ # @return [Hash] the deserialized object
919
+ #
920
+ # source://vcr//lib/vcr/cassette/serializers/psych.rb#45
921
+ def deserialize(string); end
922
+
923
+ # The file extension to use for this serializer.
924
+ #
925
+ # @return [String] "yml"
926
+ #
927
+ # source://vcr//lib/vcr/cassette/serializers/psych.rb#25
928
+ def file_extension; end
929
+
930
+ # Serializes the given hash using Psych.
931
+ #
932
+ # @param hash [Hash] the object to serialize
933
+ # @return [String] the YAML string
934
+ #
935
+ # source://vcr//lib/vcr/cassette/serializers/psych.rb#33
936
+ def serialize(hash); end
937
+ end
938
+
939
+ # @private
940
+ #
941
+ # source://vcr//lib/vcr/cassette/serializers/psych.rb#17
942
+ VCR::Cassette::Serializers::Psych::ENCODING_ERRORS = T.let(T.unsafe(nil), Array)
943
+
944
+ # @private
945
+ #
946
+ # source://vcr//lib/vcr/cassette/serializers/psych.rb#20
947
+ VCR::Cassette::Serializers::Psych::SYNTAX_ERRORS = T.let(T.unsafe(nil), Array)
948
+
949
+ # The Syck serializer. Syck is the legacy YAML engine in ruby 1.8 and 1.9.
950
+ #
951
+ # @see JSON
952
+ # @see Psych
953
+ # @see YAML
954
+ #
955
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#11
956
+ module VCR::Cassette::Serializers::Syck
957
+ extend ::VCR::Cassette::Serializers::Syck
958
+ extend ::VCR::Cassette::EncodingErrorHandling
959
+ extend ::VCR::Cassette::SyntaxErrorHandling
960
+
961
+ # Deserializes the given string using Syck.
962
+ #
963
+ # @param string [String] the YAML string
964
+ # @return [Hash] the deserialized object
965
+ #
966
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#43
967
+ def deserialize(string); end
968
+
969
+ # The file extension to use for this serializer.
970
+ #
971
+ # @return [String] "yml"
972
+ #
973
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#25
974
+ def file_extension; end
975
+
976
+ # Serializes the given hash using Syck.
977
+ #
978
+ # @param hash [Hash] the object to serialize
979
+ # @return [String] the YAML string
980
+ #
981
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#33
982
+ def serialize(hash); end
983
+
984
+ private
985
+
986
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#53
987
+ def using_syck; end
988
+ end
989
+
990
+ # @private
991
+ #
992
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#17
993
+ VCR::Cassette::Serializers::Syck::ENCODING_ERRORS = T.let(T.unsafe(nil), Array)
994
+
995
+ # @private
996
+ #
997
+ # source://vcr//lib/vcr/cassette/serializers/syck.rb#20
998
+ VCR::Cassette::Serializers::Syck::SYNTAX_ERRORS = T.let(T.unsafe(nil), Array)
999
+
1000
+ # The YAML serializer. This will use either Psych or Syck, which ever your
1001
+ # ruby interpreter defaults to. You can also force VCR to use Psych or Syck by
1002
+ # using one of those serializers.
1003
+ #
1004
+ # @see JSON
1005
+ # @see Psych
1006
+ # @see Syck
1007
+ #
1008
+ # source://vcr//lib/vcr/cassette/serializers/yaml.rb#13
1009
+ module VCR::Cassette::Serializers::YAML
1010
+ extend ::VCR::Cassette::Serializers::YAML
1011
+ extend ::VCR::Cassette::EncodingErrorHandling
1012
+ extend ::VCR::Cassette::SyntaxErrorHandling
1013
+
1014
+ # Deserializes the given string using YAML.
1015
+ #
1016
+ # @param string [String] the YAML string
1017
+ # @return [Hash] the deserialized object
1018
+ #
1019
+ # source://vcr//lib/vcr/cassette/serializers/yaml.rb#47
1020
+ def deserialize(string); end
1021
+
1022
+ # The file extension to use for this serializer.
1023
+ #
1024
+ # @return [String] "yml"
1025
+ #
1026
+ # source://vcr//lib/vcr/cassette/serializers/yaml.rb#27
1027
+ def file_extension; end
1028
+
1029
+ # Serializes the given hash using YAML.
1030
+ #
1031
+ # @param hash [Hash] the object to serialize
1032
+ # @return [String] the YAML string
1033
+ #
1034
+ # source://vcr//lib/vcr/cassette/serializers/yaml.rb#35
1035
+ def serialize(hash); end
1036
+ end
1037
+
1038
+ # @private
1039
+ #
1040
+ # source://vcr//lib/vcr/cassette/serializers/yaml.rb#19
1041
+ VCR::Cassette::Serializers::YAML::ENCODING_ERRORS = T.let(T.unsafe(nil), Array)
1042
+
1043
+ # @private
1044
+ #
1045
+ # source://vcr//lib/vcr/cassette/serializers/yaml.rb#22
1046
+ VCR::Cassette::Serializers::YAML::SYNTAX_ERRORS = T.let(T.unsafe(nil), Array)
1047
+
1048
+ # @private
1049
+ #
1050
+ # source://vcr//lib/vcr/cassette/serializers.rb#59
1051
+ module VCR::Cassette::SyntaxErrorHandling
1052
+ # source://vcr//lib/vcr/cassette/serializers.rb#60
1053
+ def handle_syntax_errors; end
1054
+ end
1055
+
1056
+ # The supported record modes.
1057
+ #
1058
+ # * :all -- Record every HTTP interactions; do not play any back.
1059
+ # * :none -- Do not record any HTTP interactions; play them back.
1060
+ # * :new_episodes -- Playback previously recorded HTTP interactions and record new ones.
1061
+ # * :once -- Record the HTTP interactions if the cassette has not already been recorded;
1062
+ # otherwise, playback the HTTP interactions.
1063
+ #
1064
+ # source://vcr//lib/vcr/cassette.rb#17
1065
+ VCR::Cassette::VALID_RECORD_MODES = T.let(T.unsafe(nil), Array)
1066
+
1067
+ # Mutex to synchronize access to cassettes in a threaded environment
1068
+ #
1069
+ # source://vcr//lib/vcr.rb#27
1070
+ VCR::CassetteMutex = T.let(T.unsafe(nil), Thread::Mutex)
1071
+
1072
+ # Stores the VCR configuration.
1073
+ #
1074
+ # source://vcr//lib/vcr/configuration.rb#7
1075
+ class VCR::Configuration
1076
+ include ::VCR::VariableArgsBlockCaller
1077
+ include ::VCR::Hooks
1078
+ include ::VCR::Configuration::DefinedHooks
1079
+ include ::VCR::Logger::Mixin
1080
+ extend ::VCR::Hooks::ClassMethods
1081
+
1082
+ # @return [Configuration] a new instance of Configuration
1083
+ #
1084
+ # source://vcr//lib/vcr/configuration.rb#490
1085
+ def initialize; end
1086
+
1087
+ # Adds a callback that will be called with each HTTP request after it is complete.
1088
+ #
1089
+ # @example
1090
+ # VCR.configure do |c|
1091
+ # c.after_http_request(:ignored?) do |request, response|
1092
+ # puts "Request: #{request.method} #{request.uri}"
1093
+ # puts "Response: #{response.status.code}"
1094
+ # end
1095
+ # end
1096
+ # @param filters [optional splat of #to_proc] one or more filters to apply.
1097
+ # The objects provided will be converted to procs using `#to_proc`. If provided,
1098
+ # the callback will only be invoked if these procs all return `true`.
1099
+ # @see #before_http_request
1100
+ # @see #around_http_request
1101
+ # @yield the callback
1102
+ # @yieldparam request [VCR::Request::Typed] the request that is being made
1103
+ # @yieldparam response [VCR::Response] the response from the request
1104
+ #
1105
+ # source://vcr//lib/vcr/configuration.rb#366
1106
+ def after_http_request(*filters); end
1107
+
1108
+ # Determines how VCR treats HTTP requests that are made when
1109
+ # no VCR cassette is in use. When set to `true`, requests made
1110
+ # when there is no VCR cassette in use will be allowed. When set
1111
+ # to `false` (the default), an {VCR::Errors::UnhandledHTTPRequestError}
1112
+ # will be raised for any HTTP request made when there is no
1113
+ # cassette in use.
1114
+ #
1115
+ # @overload allow_http_connections_when_no_cassette?
1116
+ # @overload allow_http_connections_when_no_cassette=
1117
+ #
1118
+ # source://vcr//lib/vcr/configuration.rb#129
1119
+ def allow_http_connections_when_no_cassette=(_arg0); end
1120
+
1121
+ # @private (documented above)
1122
+ # @return [Boolean]
1123
+ #
1124
+ # source://vcr//lib/vcr/configuration.rb#131
1125
+ def allow_http_connections_when_no_cassette?; end
1126
+
1127
+ # Adds a callback that will be executed around each HTTP request.
1128
+ #
1129
+ # @example
1130
+ # VCR.configure do |c|
1131
+ # c.around_http_request(lambda {|r| r.uri =~ /api.geocoder.com/}) do |request|
1132
+ # # extract an address like "1700 E Pine St, Seattle, WA"
1133
+ # # from a query like "address=1700+E+Pine+St%2C+Seattle%2C+WA"
1134
+ # address = CGI.unescape(URI(request.uri).query.split('=').last)
1135
+ # VCR.use_cassette("geocoding/#{address}", &request)
1136
+ # end
1137
+ # end
1138
+ # @note This method can only be used on ruby interpreters that support
1139
+ # fibers (i.e. 1.9+). On 1.8 you can use separate `before_http_request` and
1140
+ # `after_http_request` hooks.
1141
+ # @note You _must_ call `request.proceed` or pass the request as a proc on to a
1142
+ # method that yields to a block (i.e. `some_method(&request)`).
1143
+ # @param filters [optional splat of #to_proc] one or more filters to apply.
1144
+ # The objects provided will be converted to procs using `#to_proc`. If provided,
1145
+ # the callback will only be invoked if these procs all return `true`.
1146
+ # @raise [VCR::Errors::NotSupportedError] if the fiber library cannot be loaded.
1147
+ # @see #before_http_request
1148
+ # @see #after_http_request
1149
+ # @yield the callback
1150
+ # @yieldparam request [VCR::Request::FiberAware] the request that is being made
1151
+ #
1152
+ # source://vcr//lib/vcr/configuration.rb#395
1153
+ def around_http_request(*filters, &block); end
1154
+
1155
+ # Adds a callback that will be called before a previously recorded
1156
+ # HTTP interaction is loaded for playback.
1157
+ #
1158
+ # @example
1159
+ # VCR.configure do |c|
1160
+ # # Don't playback transient 5xx errors
1161
+ # c.before_playback do |interaction|
1162
+ # interaction.ignore! if interaction.response.status.code >= 500
1163
+ # end
1164
+ #
1165
+ # # Change a response header for playback
1166
+ # c.before_playback(:twilio) do |interaction|
1167
+ # interaction.response.headers['X-Foo-Bar'] = 'Bazz'
1168
+ # end
1169
+ # end
1170
+ # @param tag [(optional) Symbol] Used to apply this hook to only cassettes that match
1171
+ # the given tag.
1172
+ # @see #before_record
1173
+ # @yield the callback
1174
+ # @yieldparam interaction [VCR::HTTPInteraction::HookAware] The interaction that is being
1175
+ # loaded.
1176
+ # @yieldparam cassette [(optional) VCR::Cassette] The current cassette.
1177
+ #
1178
+ # source://vcr//lib/vcr/configuration.rb#325
1179
+ def before_playback(tag = T.unsafe(nil), &block); end
1180
+
1181
+ # Adds a callback that will be called before the recorded HTTP interactions
1182
+ # are serialized and written to disk.
1183
+ #
1184
+ # @example
1185
+ # VCR.configure do |c|
1186
+ # # Don't record transient 5xx errors
1187
+ # c.before_record do |interaction|
1188
+ # interaction.ignore! if interaction.response.status.code >= 500
1189
+ # end
1190
+ #
1191
+ # # Modify the response body for cassettes tagged with :twilio
1192
+ # c.before_record(:twilio) do |interaction|
1193
+ # interaction.response.body.downcase!
1194
+ # end
1195
+ # end
1196
+ # @param tag [(optional) Symbol] Used to apply this hook to only cassettes that match
1197
+ # the given tag.
1198
+ # @see #before_playback
1199
+ # @yield the callback
1200
+ # @yieldparam interaction [VCR::HTTPInteraction::HookAware] The interaction that will be
1201
+ # serialized and written to disk.
1202
+ # @yieldparam cassette [(optional) VCR::Cassette] The current cassette.
1203
+ #
1204
+ # source://vcr//lib/vcr/configuration.rb#297
1205
+ def before_record(tag = T.unsafe(nil), &block); end
1206
+
1207
+ # Gets the directory to read cassettes from and write cassettes to.
1208
+ #
1209
+ # @return [String] the directory to read cassettes from and write cassettes to
1210
+ #
1211
+ # source://vcr//lib/vcr/configuration.rb#15
1212
+ def cassette_library_dir; end
1213
+
1214
+ # Sets the directory to read cassettes from and writes cassettes to.
1215
+ #
1216
+ # @example
1217
+ # VCR.configure do |c|
1218
+ # c.cassette_library_dir = 'spec/cassettes'
1219
+ # end
1220
+ # @note This is only necessary if you use the `:file_system`
1221
+ # cassette persister (the default).
1222
+ # @param dir [String] the directory to read cassettes from and write cassettes to
1223
+ # @return [void]
1224
+ #
1225
+ # source://vcr//lib/vcr/configuration.rb#30
1226
+ def cassette_library_dir=(dir); end
1227
+
1228
+ # Gets the registry of cassette persisters. Use it to register a custom persister.
1229
+ #
1230
+ # @example
1231
+ # VCR.configure do |c|
1232
+ # c.cassette_persisters[:my_custom_persister] = my_custom_persister
1233
+ # end
1234
+ # @note Custom persisters must implement the following interface:
1235
+ #
1236
+ # * `persister[storage_key]` # returns previously persisted content
1237
+ # * `persister[storage_key] = content` # persists given content
1238
+ # @return [VCR::Cassette::Persisters] the cassette persister registry object.
1239
+ #
1240
+ # source://vcr//lib/vcr/configuration.rb#269
1241
+ def cassette_persisters; end
1242
+
1243
+ # Gets the registry of cassette serializers. Use it to register a custom serializer.
1244
+ #
1245
+ # @example
1246
+ # VCR.configure do |c|
1247
+ # c.cassette_serializers[:my_custom_serializer] = my_custom_serializer
1248
+ # end
1249
+ # @note Custom serializers must implement the following interface:
1250
+ #
1251
+ # * `file_extension # => String`
1252
+ # * `serialize(Hash) # => String`
1253
+ # * `deserialize(String) # => Hash`
1254
+ # @return [VCR::Cassette::Serializers] the cassette serializer registry object.
1255
+ #
1256
+ # source://vcr//lib/vcr/configuration.rb#253
1257
+ def cassette_serializers; end
1258
+
1259
+ # Configures RSpec to use a VCR cassette for any example
1260
+ # tagged with `:vcr`.
1261
+ #
1262
+ # source://vcr//lib/vcr/configuration.rb#418
1263
+ def configure_rspec_metadata!; end
1264
+
1265
+ # An object to log debug output to.
1266
+ #
1267
+ # @example
1268
+ # VCR.configure do |c|
1269
+ # c.debug_logger = $stderr
1270
+ # end
1271
+ # @example
1272
+ # VCR.configure do |c|
1273
+ # c.debug_logger = File.open('vcr.log', 'w')
1274
+ # end
1275
+ # @overload debug_logger
1276
+ # @overload debug_logger=
1277
+ #
1278
+ # source://vcr//lib/vcr/configuration.rb#440
1279
+ def debug_logger; end
1280
+
1281
+ # @private (documented above)
1282
+ #
1283
+ # source://vcr//lib/vcr/configuration.rb#442
1284
+ def debug_logger=(value); end
1285
+
1286
+ # Default options to apply to every cassette.
1287
+ #
1288
+ # @example
1289
+ # VCR.configure do |c|
1290
+ # c.default_cassette_options = { :record => :new_episodes }
1291
+ # end
1292
+ # @note {VCR#insert_cassette} for the list of valid options.
1293
+ # @overload default_cassette_options
1294
+ # @overload default_cassette_options=
1295
+ #
1296
+ # source://vcr//lib/vcr/configuration.rb#46
1297
+ def default_cassette_options; end
1298
+
1299
+ # Sets the default options that apply to every cassette.
1300
+ #
1301
+ # source://vcr//lib/vcr/configuration.rb#49
1302
+ def default_cassette_options=(overrides); end
1303
+
1304
+ # Sets up a {#before_record} and a {#before_playback} hook that will
1305
+ # insert a placeholder string in the cassette in place of another string.
1306
+ # You can use this as a generic way to interpolate a variable into the
1307
+ # cassette for a unique string. It's particularly useful for unique
1308
+ # sensitive strings like API keys and passwords.
1309
+ #
1310
+ # @example
1311
+ # VCR.configure do |c|
1312
+ # # Put "<GITHUB_API_KEY>" in place of the actual API key in
1313
+ # # our cassettes so we don't have to commit to source control.
1314
+ # c.filter_sensitive_data('<GITHUB_API_KEY>') { GithubClient.api_key }
1315
+ #
1316
+ # # Put a "<USER_ID>" placeholder variable in our cassettes tagged with
1317
+ # # :user_cassette since it can be different for different test runs.
1318
+ # c.define_cassette_placeholder('<USER_ID>', :user_cassette) { User.last.id }
1319
+ # end
1320
+ # @param placeholder [String] The placeholder string.
1321
+ # @param tag [Symbol] Set this to apply this only to cassettes
1322
+ # with a matching tag; otherwise it will apply to every cassette.
1323
+ # @yield block that determines what string to replace
1324
+ # @yieldparam interaction [(optional) VCR::HTTPInteraction::HookAware] the HTTP interaction
1325
+ # @yieldreturn the string to replace
1326
+ #
1327
+ # source://vcr//lib/vcr/configuration.rb#225
1328
+ def define_cassette_placeholder(placeholder, tag = T.unsafe(nil), &block); end
1329
+
1330
+ # Sets up a {#before_record} and a {#before_playback} hook that will
1331
+ # insert a placeholder string in the cassette in place of another string.
1332
+ # You can use this as a generic way to interpolate a variable into the
1333
+ # cassette for a unique string. It's particularly useful for unique
1334
+ # sensitive strings like API keys and passwords.
1335
+ #
1336
+ # @example
1337
+ # VCR.configure do |c|
1338
+ # # Put "<GITHUB_API_KEY>" in place of the actual API key in
1339
+ # # our cassettes so we don't have to commit to source control.
1340
+ # c.filter_sensitive_data('<GITHUB_API_KEY>') { GithubClient.api_key }
1341
+ #
1342
+ # # Put a "<USER_ID>" placeholder variable in our cassettes tagged with
1343
+ # # :user_cassette since it can be different for different test runs.
1344
+ # c.define_cassette_placeholder('<USER_ID>', :user_cassette) { User.last.id }
1345
+ # end
1346
+ # @param placeholder [String] The placeholder string.
1347
+ # @param tag [Symbol] Set this to apply this only to cassettes
1348
+ # with a matching tag; otherwise it will apply to every cassette.
1349
+ # @yield block that determines what string to replace
1350
+ # @yieldparam interaction [(optional) VCR::HTTPInteraction::HookAware] the HTTP interaction
1351
+ # @yieldreturn the string to replace
1352
+ #
1353
+ # source://vcr//lib/vcr/configuration.rb#225
1354
+ def filter_sensitive_data(placeholder, tag = T.unsafe(nil), &block); end
1355
+
1356
+ # Configures which libraries VCR will hook into to intercept HTTP requests.
1357
+ #
1358
+ # @example
1359
+ # VCR.configure do |c|
1360
+ # c.hook_into :webmock, :typhoeus
1361
+ # end
1362
+ # @param hooks [Array<Symbol>] List of libraries. Valid values are
1363
+ # `:webmock`, `:typhoeus`, `:excon` and `:faraday`.
1364
+ # @raise [ArgumentError] when given an unsupported library name.
1365
+ # @raise [VCR::Errors::LibraryVersionTooLowError] when the version
1366
+ # of a library you are using is too low for VCR to support.
1367
+ #
1368
+ # source://vcr//lib/vcr/configuration.rb#65
1369
+ def hook_into(*hooks); end
1370
+
1371
+ # Specifies host(s) that VCR should ignore.
1372
+ #
1373
+ # @param hosts [Array<String>] List of hosts to ignore
1374
+ # @see #ignore_localhost=
1375
+ # @see #ignore_request
1376
+ #
1377
+ # source://vcr//lib/vcr/configuration.rb#75
1378
+ def ignore_host(*hosts); end
1379
+
1380
+ # Specifies host(s) that VCR should ignore.
1381
+ #
1382
+ # @param hosts [Array<String>] List of hosts to ignore
1383
+ # @see #ignore_localhost=
1384
+ # @see #ignore_request
1385
+ #
1386
+ # source://vcr//lib/vcr/configuration.rb#75
1387
+ def ignore_hosts(*hosts); end
1388
+
1389
+ # Sets whether or not VCR should ignore localhost requests.
1390
+ #
1391
+ # @param value [Boolean] the value to set
1392
+ # @see #ignore_hosts
1393
+ # @see #ignore_request
1394
+ #
1395
+ # source://vcr//lib/vcr/configuration.rb#94
1396
+ def ignore_localhost=(value); end
1397
+
1398
+ # Defines what requests to ignore using a block.
1399
+ #
1400
+ # @example
1401
+ # VCR.configure do |c|
1402
+ # c.ignore_request do |request|
1403
+ # uri = URI(request.uri)
1404
+ # # ignore only localhost requests to port 7500
1405
+ # uri.host == 'localhost' && uri.port == 7500
1406
+ # end
1407
+ # end
1408
+ # @yield the callback
1409
+ # @yieldparam request [VCR::Request] the HTTP request
1410
+ # @yieldreturn [Boolean] whether or not to ignore the request
1411
+ #
1412
+ # source://vcr//lib/vcr/configuration.rb#112
1413
+ def ignore_request(&block); end
1414
+
1415
+ # Logger object that provides logging APIs and helper methods.
1416
+ #
1417
+ # @private
1418
+ #
1419
+ # source://vcr//lib/vcr/configuration.rb#454
1420
+ def logger; end
1421
+
1422
+ # @param http_message [#body, #headers] the `VCR::Request` or `VCR::Response` object being serialized
1423
+ # @return [Boolean] whether or not the body of the given HTTP message should
1424
+ # be base64 encoded during serialization in order to preserve the bytes exactly.
1425
+ # @see #preserve_exact_body_bytes
1426
+ #
1427
+ # source://vcr//lib/vcr/configuration.rb#484
1428
+ def preserve_exact_body_bytes_for?(http_message); end
1429
+
1430
+ # Sets a parser for VCR to use when parsing query strings for request
1431
+ # comparisons. The new parser must implement a method `call` that returns
1432
+ # an object which is both equalivant and consistent when given an HTTP
1433
+ # query string of possibly differing value ordering.
1434
+ #
1435
+ # * `#== # => Boolean`
1436
+ #
1437
+ # The `#==` method must return true if both objects represent the
1438
+ # same query string.
1439
+ #
1440
+ # This defaults to `CGI.parse` from the ruby standard library.
1441
+ #
1442
+ # @overload query_parser
1443
+ # @overload query_parser=
1444
+ #
1445
+ # source://vcr//lib/vcr/configuration.rb#151
1446
+ def query_parser; end
1447
+
1448
+ # Sets a parser for VCR to use when parsing query strings for request
1449
+ # comparisons. The new parser must implement a method `call` that returns
1450
+ # an object which is both equalivant and consistent when given an HTTP
1451
+ # query string of possibly differing value ordering.
1452
+ #
1453
+ # * `#== # => Boolean`
1454
+ #
1455
+ # The `#==` method must return true if both objects represent the
1456
+ # same query string.
1457
+ #
1458
+ # This defaults to `CGI.parse` from the ruby standard library.
1459
+ #
1460
+ # @overload query_parser
1461
+ # @overload query_parser=
1462
+ #
1463
+ # source://vcr//lib/vcr/configuration.rb#151
1464
+ def query_parser=(_arg0); end
1465
+
1466
+ # Registers a request matcher for later use.
1467
+ #
1468
+ # @example
1469
+ # VCR.configure do |c|
1470
+ # c.register_request_matcher :port do |request_1, request_2|
1471
+ # URI(request_1.uri).port == URI(request_2.uri).port
1472
+ # end
1473
+ # end
1474
+ #
1475
+ # VCR.use_cassette("my_cassette", :match_requests_on => [:method, :host, :port]) do
1476
+ # # ...
1477
+ # end
1478
+ # @param name [Symbol] the name of the request matcher
1479
+ # @yield the request matcher
1480
+ # @yieldparam request_1 [VCR::Request] One request
1481
+ # @yieldparam request_2 [VCR::Request] The other request
1482
+ # @yieldreturn [Boolean] whether or not these two requests should be considered
1483
+ # equivalent
1484
+ #
1485
+ # source://vcr//lib/vcr/configuration.rb#198
1486
+ def register_request_matcher(name, &block); end
1487
+
1488
+ # @deprecated Use #hook_into instead.
1489
+ # @see #hook_into
1490
+ #
1491
+ # source://vcr//lib/vcr/deprecations.rb#26
1492
+ def stub_with(*adapters); end
1493
+
1494
+ # Specifies host(s) that VCR should stop ignoring.
1495
+ #
1496
+ # @param hosts [Array<String>] List of hosts to unignore
1497
+ # @see #ignore_hosts
1498
+ #
1499
+ # source://vcr//lib/vcr/configuration.rb#84
1500
+ def unignore_host(*hosts); end
1501
+
1502
+ # Specifies host(s) that VCR should stop ignoring.
1503
+ #
1504
+ # @param hosts [Array<String>] List of hosts to unignore
1505
+ # @see #ignore_hosts
1506
+ #
1507
+ # source://vcr//lib/vcr/configuration.rb#84
1508
+ def unignore_hosts(*hosts); end
1509
+
1510
+ # Sets a parser for VCR to use when parsing URIs. The new parser
1511
+ # must implement a method `parse` that returns an instance of the
1512
+ # URI object. This URI object must implement the following
1513
+ # interface:
1514
+ #
1515
+ # * `scheme # => String`
1516
+ # * `host # => String`
1517
+ # * `port # => Fixnum`
1518
+ # * `path # => String`
1519
+ # * `query # => String`
1520
+ # * `#port=`
1521
+ # * `#query=`
1522
+ # * `#to_s # => String`
1523
+ # * `#== # => Boolean`
1524
+ #
1525
+ # The `#==` method must return true if both URI objects represent the
1526
+ # same URI.
1527
+ #
1528
+ # This defaults to `URI` from the ruby standard library.
1529
+ #
1530
+ # @overload uri_parser
1531
+ # @overload uri_parser=
1532
+ #
1533
+ # source://vcr//lib/vcr/configuration.rb#177
1534
+ def uri_parser; end
1535
+
1536
+ # Sets a parser for VCR to use when parsing URIs. The new parser
1537
+ # must implement a method `parse` that returns an instance of the
1538
+ # URI object. This URI object must implement the following
1539
+ # interface:
1540
+ #
1541
+ # * `scheme # => String`
1542
+ # * `host # => String`
1543
+ # * `port # => Fixnum`
1544
+ # * `path # => String`
1545
+ # * `query # => String`
1546
+ # * `#port=`
1547
+ # * `#query=`
1548
+ # * `#to_s # => String`
1549
+ # * `#== # => Boolean`
1550
+ #
1551
+ # The `#==` method must return true if both URI objects represent the
1552
+ # same URI.
1553
+ #
1554
+ # This defaults to `URI` from the ruby standard library.
1555
+ #
1556
+ # @overload uri_parser
1557
+ # @overload uri_parser=
1558
+ #
1559
+ # source://vcr//lib/vcr/configuration.rb#177
1560
+ def uri_parser=(_arg0); end
1561
+
1562
+ private
1563
+
1564
+ # source://vcr//lib/vcr/configuration.rb#528
1565
+ def create_fiber_for(fiber_errors, hook_declaration, proc); end
1566
+
1567
+ # source://vcr//lib/vcr/configuration.rb#510
1568
+ def load_library_hook(hook); end
1569
+
1570
+ # source://vcr//lib/vcr/configuration.rb#581
1571
+ def log_prefix; end
1572
+
1573
+ # source://vcr//lib/vcr/configuration.rb#563
1574
+ def register_built_in_hooks; end
1575
+
1576
+ # source://vcr//lib/vcr/configuration.rb#558
1577
+ def request_filter_from(object); end
1578
+
1579
+ # source://vcr//lib/vcr/configuration.rb#518
1580
+ def resume_fiber(fiber, fiber_errors, response, hook_declaration); end
1581
+
1582
+ # source://vcr//lib/vcr/configuration.rb#547
1583
+ def start_new_fiber_for(request, fibers, fiber_errors, hook_declaration, proc); end
1584
+
1585
+ # source://vcr//lib/vcr/configuration.rb#553
1586
+ def tag_filter_from(tag); end
1587
+ end
1588
+
1589
+ # source://vcr//lib/vcr/configuration.rb#0
1590
+ module VCR::Configuration::DefinedHooks
1591
+ # source://vcr//lib/vcr/util/hooks.rb#55
1592
+ def after_http_request(*filters, &hook); end
1593
+
1594
+ # source://vcr//lib/vcr/util/hooks.rb#55
1595
+ def after_library_hooks_loaded(*filters, &hook); end
1596
+
1597
+ # source://vcr//lib/vcr/util/hooks.rb#55
1598
+ def before_http_request(*filters, &hook); end
1599
+
1600
+ # source://vcr//lib/vcr/util/hooks.rb#55
1601
+ def before_playback(*filters, &hook); end
1602
+
1603
+ # source://vcr//lib/vcr/util/hooks.rb#55
1604
+ def before_record(*filters, &hook); end
1605
+
1606
+ # source://vcr//lib/vcr/util/hooks.rb#55
1607
+ def preserve_exact_body_bytes(*filters, &hook); end
1608
+ end
1609
+
1610
+ # Provides integration with Cucumber using tags.
1611
+ #
1612
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#3
1613
+ class VCR::CucumberTags
1614
+ # @private
1615
+ # @return [CucumberTags] a new instance of CucumberTags
1616
+ #
1617
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#19
1618
+ def initialize(main_object); end
1619
+
1620
+ # Adds `Before` and `After` cucumber hooks for the named tags that
1621
+ # will cause a VCR cassette to be used for scenarios with matching tags.
1622
+ #
1623
+ # @param tag_names [Array<String,Hash>] the cucumber scenario tags. If
1624
+ # the last argument is a hash it is treated as cassette options.
1625
+ # - `:use_scenario_name => true` to automatically name the
1626
+ # cassette according to the scenario name.
1627
+ #
1628
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#30
1629
+ def tag(*tag_names); end
1630
+
1631
+ # Adds `Before` and `After` cucumber hooks for the named tags that
1632
+ # will cause a VCR cassette to be used for scenarios with matching tags.
1633
+ #
1634
+ # @param tag_names [Array<String,Hash>] the cucumber scenario tags. If
1635
+ # the last argument is a hash it is treated as cassette options.
1636
+ # - `:use_scenario_name => true` to automatically name the
1637
+ # cassette according to the scenario name.
1638
+ #
1639
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#30
1640
+ def tags(*tag_names); end
1641
+
1642
+ class << self
1643
+ # @private
1644
+ #
1645
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#11
1646
+ def add_tag(tag); end
1647
+
1648
+ # @private
1649
+ #
1650
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#6
1651
+ def tags; end
1652
+ end
1653
+ end
1654
+
1655
+ # Constructs a cassette name from a Cucumber 2 scenario outline
1656
+ #
1657
+ # @private
1658
+ #
1659
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#84
1660
+ class VCR::CucumberTags::ScenarioNameBuilder
1661
+ # @return [ScenarioNameBuilder] a new instance of ScenarioNameBuilder
1662
+ #
1663
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#85
1664
+ def initialize(test_case); end
1665
+
1666
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#90
1667
+ def cassette_name; end
1668
+
1669
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#100
1670
+ def examples_table(*_arg0); end
1671
+
1672
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#103
1673
+ def examples_table_row(row); end
1674
+
1675
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#94
1676
+ def feature(feature); end
1677
+
1678
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#100
1679
+ def scenario(*_arg0); end
1680
+
1681
+ # source://vcr//lib/vcr/test_frameworks/cucumber.rb#94
1682
+ def scenario_outline(feature); end
1683
+ end
1684
+
1685
+ # @private
1686
+ #
1687
+ # source://vcr//lib/vcr/deprecations.rb#33
1688
+ module VCR::Deprecations; end
1689
+
1690
+ # source://vcr//lib/vcr/deprecations.rb#34
1691
+ module VCR::Deprecations::Middleware; end
1692
+
1693
+ # @private
1694
+ #
1695
+ # source://vcr//lib/vcr/deprecations.rb#36
1696
+ module VCR::Deprecations::Middleware::Faraday
1697
+ # source://vcr//lib/vcr/deprecations.rb#37
1698
+ def initialize(*args); end
1699
+ end
1700
+
1701
+ # Namespace for VCR errors.
1702
+ #
1703
+ # source://vcr//lib/vcr/errors.rb#3
1704
+ module VCR::Errors; end
1705
+
1706
+ # Error raised when an `around_http_request` hook is used improperly.
1707
+ #
1708
+ # @see VCR::Configuration#around_http_request
1709
+ #
1710
+ # source://vcr//lib/vcr/errors.rb#36
1711
+ class VCR::Errors::AroundHTTPRequestHookError < ::VCR::Errors::Error; end
1712
+
1713
+ # Error raised when VCR is turned off while a cassette is in use.
1714
+ #
1715
+ # @see VCR#turn_off!
1716
+ # @see VCR#turned_off
1717
+ #
1718
+ # source://vcr//lib/vcr/errors.rb#10
1719
+ class VCR::Errors::CassetteInUseError < ::VCR::Errors::Error; end
1720
+
1721
+ # Error raised when you attempt to eject a cassette inserted by another
1722
+ # thread.
1723
+ #
1724
+ # source://vcr//lib/vcr/errors.rb#56
1725
+ class VCR::Errors::EjectLinkedCassetteError < ::VCR::Errors::Error; end
1726
+
1727
+ # Base class for all VCR errors.
1728
+ #
1729
+ # source://vcr//lib/vcr/errors.rb#5
1730
+ class VCR::Errors::Error < ::StandardError; end
1731
+
1732
+ # Error raised when a VCR 1.x cassette is used with VCR 2.
1733
+ #
1734
+ # source://vcr//lib/vcr/errors.rb#32
1735
+ class VCR::Errors::InvalidCassetteFormatError < ::VCR::Errors::Error; end
1736
+
1737
+ # Error raised when the version of one of the libraries that VCR hooks into
1738
+ # is too low for VCR to support.
1739
+ #
1740
+ # @see VCR::Configuration#hook_into
1741
+ #
1742
+ # source://vcr//lib/vcr/errors.rb#26
1743
+ class VCR::Errors::LibraryVersionTooLowError < ::VCR::Errors::Error; end
1744
+
1745
+ # Error raised when an cassette ERB template is rendered and a
1746
+ # variable is missing.
1747
+ #
1748
+ # @see VCR#insert_cassette
1749
+ # @see VCR#use_cassette
1750
+ #
1751
+ # source://vcr//lib/vcr/errors.rb#21
1752
+ class VCR::Errors::MissingERBVariableError < ::VCR::Errors::Error; end
1753
+
1754
+ # Error raised when you attempt to use a VCR feature that is not
1755
+ # supported on your ruby interpreter.
1756
+ #
1757
+ # @see VCR::Configuration#around_http_request
1758
+ #
1759
+ # source://vcr//lib/vcr/errors.rb#41
1760
+ class VCR::Errors::NotSupportedError < ::VCR::Errors::Error; end
1761
+
1762
+ # Error raised when a VCR cassette is inserted while VCR is turned off.
1763
+ #
1764
+ # @see VCR#insert_cassette
1765
+ # @see VCR#use_cassette
1766
+ #
1767
+ # source://vcr//lib/vcr/errors.rb#15
1768
+ class VCR::Errors::TurnedOffError < ::VCR::Errors::Error; end
1769
+
1770
+ # Error raised when an HTTP request is made that VCR is unable to handle.
1771
+ #
1772
+ # @note VCR will raise this to force you to do something about the
1773
+ # HTTP request. The idea is that you want to handle _every_ HTTP
1774
+ # request in your test suite. The error message will give you
1775
+ # suggestions for how to deal with the request.
1776
+ #
1777
+ # source://vcr//lib/vcr/errors.rb#63
1778
+ class VCR::Errors::UnhandledHTTPRequestError < ::VCR::Errors::Error
1779
+ # Constructs the error.
1780
+ #
1781
+ # @param request [VCR::Request] the unhandled request.
1782
+ # @return [UnhandledHTTPRequestError] a new instance of UnhandledHTTPRequestError
1783
+ #
1784
+ # source://vcr//lib/vcr/errors.rb#70
1785
+ def initialize(request); end
1786
+
1787
+ # The HTTP request.
1788
+ #
1789
+ # source://vcr//lib/vcr/errors.rb#65
1790
+ def request; end
1791
+
1792
+ private
1793
+
1794
+ # source://vcr//lib/vcr/errors.rb#136
1795
+ def cassettes_description; end
1796
+
1797
+ # source://vcr//lib/vcr/errors.rb#148
1798
+ def cassettes_list; end
1799
+
1800
+ # source://vcr//lib/vcr/errors.rb#81
1801
+ def construct_message; end
1802
+
1803
+ # source://vcr//lib/vcr/errors.rb#90
1804
+ def current_cassettes; end
1805
+
1806
+ # source://vcr//lib/vcr/errors.rb#118
1807
+ def current_matchers; end
1808
+
1809
+ # source://vcr//lib/vcr/errors.rb#183
1810
+ def format_bullet_point(lines, index); end
1811
+
1812
+ # source://vcr//lib/vcr/errors.rb#189
1813
+ def format_foot_note(url, index); end
1814
+
1815
+ # source://vcr//lib/vcr/errors.rb#128
1816
+ def formatted_headers; end
1817
+
1818
+ # source://vcr//lib/vcr/errors.rb#168
1819
+ def formatted_suggestions; end
1820
+
1821
+ # @return [Boolean]
1822
+ #
1823
+ # source://vcr//lib/vcr/errors.rb#295
1824
+ def has_used_interaction_matching?; end
1825
+
1826
+ # @return [Boolean]
1827
+ #
1828
+ # source://vcr//lib/vcr/errors.rb#114
1829
+ def match_request_on_body?; end
1830
+
1831
+ # @return [Boolean]
1832
+ #
1833
+ # source://vcr//lib/vcr/errors.rb#110
1834
+ def match_request_on_headers?; end
1835
+
1836
+ # source://vcr//lib/vcr/errors.rb#299
1837
+ def match_requests_on_suggestion; end
1838
+
1839
+ # source://vcr//lib/vcr/errors.rb#277
1840
+ def no_cassette_suggestions; end
1841
+
1842
+ # source://vcr//lib/vcr/errors.rb#283
1843
+ def record_mode_suggestion; end
1844
+
1845
+ # source://vcr//lib/vcr/errors.rb#77
1846
+ def relish_version_slug; end
1847
+
1848
+ # source://vcr//lib/vcr/errors.rb#94
1849
+ def request_description; end
1850
+
1851
+ # source://vcr//lib/vcr/errors.rb#259
1852
+ def suggestion_for(key); end
1853
+
1854
+ # source://vcr//lib/vcr/errors.rb#266
1855
+ def suggestions; end
1856
+ end
1857
+
1858
+ # List of suggestions for how to configure VCR to handle the request.
1859
+ #
1860
+ # source://vcr//lib/vcr/errors.rb#194
1861
+ VCR::Errors::UnhandledHTTPRequestError::ALL_SUGGESTIONS = T.let(T.unsafe(nil), Hash)
1862
+
1863
+ # Error raised when you ask VCR to decode a compressed response
1864
+ # body but the content encoding isn't one of the known ones.
1865
+ #
1866
+ # @see VCR::Response#decompress
1867
+ #
1868
+ # source://vcr//lib/vcr/errors.rb#46
1869
+ class VCR::Errors::UnknownContentEncodingError < ::VCR::Errors::Error; end
1870
+
1871
+ # Error raised when a request matcher is requested that is not registered.
1872
+ #
1873
+ # source://vcr//lib/vcr/errors.rb#29
1874
+ class VCR::Errors::UnregisteredMatcherError < ::VCR::Errors::Error; end
1875
+
1876
+ # Error raised when you eject a cassette before all previously
1877
+ # recorded HTTP interactions are played back.
1878
+ #
1879
+ # @note Only applicable when :allow_episode_skipping is false.
1880
+ # @see VCR::HTTPInteractionList#assert_no_unused_interactions!
1881
+ #
1882
+ # source://vcr//lib/vcr/errors.rb#52
1883
+ class VCR::Errors::UnusedHTTPInteractionError < ::VCR::Errors::Error; end
1884
+
1885
+ # Represents a single interaction over HTTP, containing a request and a response.
1886
+ #
1887
+ # @attr request [Request] the request
1888
+ # @attr response [Response] the response
1889
+ # @attr recorded_at [Time] when this HTTP interaction was recorded
1890
+ #
1891
+ # source://vcr//lib/vcr/structs.rb#501
1892
+ class VCR::HTTPInteraction < ::Struct
1893
+ # @return [HTTPInteraction] a new instance of HTTPInteraction
1894
+ #
1895
+ # source://vcr//lib/vcr/structs.rb#502
1896
+ def initialize(*args); end
1897
+
1898
+ # @return [HookAware] an instance with additional capabilities
1899
+ # suitable for use in `before_record` and `before_playback` hooks.
1900
+ #
1901
+ # source://vcr//lib/vcr/structs.rb#532
1902
+ def hook_aware; end
1903
+
1904
+ # Builds a serializable hash from the HTTP interaction data.
1905
+ #
1906
+ # @return [Hash] hash that represents this HTTP interaction
1907
+ # and can be easily serialized.
1908
+ # @see HTTPInteraction.from_hash
1909
+ #
1910
+ # source://vcr//lib/vcr/structs.rb#512
1911
+ def to_hash; end
1912
+
1913
+ class << self
1914
+ # Constructs a new instance from a hash.
1915
+ #
1916
+ # @param hash [Hash] the hash to use to construct the instance.
1917
+ # @return [HTTPInteraction] the HTTP interaction
1918
+ #
1919
+ # source://vcr//lib/vcr/structs.rb#524
1920
+ def from_hash(hash); end
1921
+ end
1922
+ end
1923
+
1924
+ # Decorates an {HTTPInteraction} with additional methods useful
1925
+ # for a `before_record` or `before_playback` hook.
1926
+ #
1927
+ # source://vcr//lib/vcr/structs.rb#538
1928
+ class VCR::HTTPInteraction::HookAware
1929
+ # @return [HookAware] a new instance of HookAware
1930
+ #
1931
+ # source://vcr//lib/vcr/structs.rb#539
1932
+ def initialize(http_interaction); end
1933
+
1934
+ # Replaces a string in any part of the HTTP interaction (headers, request body,
1935
+ # response body, etc) with the given replacement text.
1936
+ #
1937
+ # @param text [#to_s] the text to replace
1938
+ # @param replacement_text [#to_s] the text to put in its place
1939
+ #
1940
+ # source://vcr//lib/vcr/structs.rb#563
1941
+ def filter!(text, replacement_text); end
1942
+
1943
+ # Flags the HTTP interaction so that VCR ignores it. This is useful in
1944
+ # a {VCR::Configuration#before_record} or {VCR::Configuration#before_playback}
1945
+ # hook so that VCR does not record or play it back.
1946
+ #
1947
+ # @see #ignored?
1948
+ #
1949
+ # source://vcr//lib/vcr/structs.rb#548
1950
+ def ignore!; end
1951
+
1952
+ # @return [Boolean] whether or not this HTTP interaction should be ignored.
1953
+ # @see #ignore!
1954
+ #
1955
+ # source://vcr//lib/vcr/structs.rb#554
1956
+ def ignored?; end
1957
+
1958
+ private
1959
+
1960
+ # source://vcr//lib/vcr/structs.rb#584
1961
+ def filter_hash!(hash, text, replacement_text); end
1962
+
1963
+ # source://vcr//lib/vcr/structs.rb#571
1964
+ def filter_object!(object, text, replacement_text); end
1965
+ end
1966
+
1967
+ # @private
1968
+ #
1969
+ # source://vcr//lib/vcr/util/hooks.rb#5
1970
+ module VCR::Hooks
1971
+ include ::VCR::VariableArgsBlockCaller
1972
+
1973
+ mixes_in_class_methods ::VCR::Hooks::ClassMethods
1974
+
1975
+ # source://vcr//lib/vcr/util/hooks.rb#34
1976
+ def clear_hooks; end
1977
+
1978
+ # @return [Boolean]
1979
+ #
1980
+ # source://vcr//lib/vcr/util/hooks.rb#44
1981
+ def has_hooks_for?(hook_type); end
1982
+
1983
+ # source://vcr//lib/vcr/util/hooks.rb#38
1984
+ def hooks; end
1985
+
1986
+ # source://vcr//lib/vcr/util/hooks.rb#28
1987
+ def invoke_hook(hook_type, *args); end
1988
+
1989
+ class << self
1990
+ # @private
1991
+ #
1992
+ # source://vcr//lib/vcr/util/hooks.rb#19
1993
+ def included(klass); end
1994
+ end
1995
+ end
1996
+
1997
+ # @private
1998
+ #
1999
+ # source://vcr//lib/vcr/util/hooks.rb#49
2000
+ module VCR::Hooks::ClassMethods
2001
+ # source://vcr//lib/vcr/util/hooks.rb#50
2002
+ def define_hook(hook_type, prepend = T.unsafe(nil)); end
2003
+ end
2004
+
2005
+ # @private
2006
+ #
2007
+ # source://vcr//lib/vcr/util/hooks.rb#9
2008
+ class VCR::Hooks::FilteredHook < ::Struct
2009
+ include ::VCR::VariableArgsBlockCaller
2010
+
2011
+ # source://vcr//lib/vcr/util/hooks.rb#12
2012
+ def conditionally_invoke(*args); end
2013
+
2014
+ # Returns the value of attribute filters
2015
+ #
2016
+ # @return [Object] the current value of filters
2017
+ def filters; end
2018
+
2019
+ # Sets the attribute filters
2020
+ #
2021
+ # @param value [Object] the value to set the attribute filters to.
2022
+ # @return [Object] the newly set value
2023
+ def filters=(_); end
2024
+
2025
+ # Returns the value of attribute hook
2026
+ #
2027
+ # @return [Object] the current value of hook
2028
+ def hook; end
2029
+
2030
+ # Sets the attribute hook
2031
+ #
2032
+ # @param value [Object] the value to set the attribute hook to.
2033
+ # @return [Object] the newly set value
2034
+ def hook=(_); end
2035
+
2036
+ class << self
2037
+ def [](*_arg0); end
2038
+ def inspect; end
2039
+ def keyword_init?; end
2040
+ def members; end
2041
+ def new(*_arg0); end
2042
+ end
2043
+ end
2044
+
2045
+ # @private
2046
+ #
2047
+ # source://vcr//lib/vcr/util/internet_connection.rb#26
2048
+ module VCR::InternetConnection
2049
+ extend ::VCR::InternetConnection
2050
+
2051
+ # @return [Boolean]
2052
+ #
2053
+ # source://vcr//lib/vcr/util/internet_connection.rb#31
2054
+ def available?; end
2055
+ end
2056
+
2057
+ # source://vcr//lib/vcr/util/internet_connection.rb#29
2058
+ VCR::InternetConnection::EXAMPLE_HOST = T.let(T.unsafe(nil), String)
2059
+
2060
+ # @private
2061
+ #
2062
+ # source://vcr//lib/vcr/library_hooks.rb#3
2063
+ class VCR::LibraryHooks
2064
+ # @return [Boolean]
2065
+ #
2066
+ # source://vcr//lib/vcr/library_hooks.rb#6
2067
+ def disabled?(hook); end
2068
+
2069
+ # Returns the value of attribute exclusive_hook.
2070
+ #
2071
+ # source://vcr//lib/vcr/library_hooks.rb#4
2072
+ def exclusive_hook; end
2073
+
2074
+ # Sets the attribute exclusive_hook
2075
+ #
2076
+ # @param value the value to set the attribute exclusive_hook to.
2077
+ #
2078
+ # source://vcr//lib/vcr/library_hooks.rb#4
2079
+ def exclusive_hook=(_arg0); end
2080
+
2081
+ # source://vcr//lib/vcr/library_hooks.rb#10
2082
+ def exclusively_enabled(hook); end
2083
+ end
2084
+
2085
+ # A Cassette wrapper for linking cassettes from another thread
2086
+ #
2087
+ # source://vcr//lib/vcr/linked_cassette.rb#6
2088
+ class VCR::LinkedCassette < ::SimpleDelegator
2089
+ # Prevents cassette ejection by raising EjectLinkedCassetteError
2090
+ #
2091
+ # @raise [Errors::EjectLinkedCassetteError]
2092
+ #
2093
+ # source://vcr//lib/vcr/linked_cassette.rb#62
2094
+ def eject(*args); end
2095
+
2096
+ # @return [Boolean] true
2097
+ #
2098
+ # source://vcr//lib/vcr/linked_cassette.rb#68
2099
+ def linked?; end
2100
+
2101
+ class << self
2102
+ # Create a new CassetteList
2103
+ #
2104
+ # @param cassettes [Array] context-owned cassettes
2105
+ # @param linked_cassettes [Array] context-unowned (linked) cassettes
2106
+ #
2107
+ # source://vcr//lib/vcr/linked_cassette.rb#57
2108
+ def list(cassettes, linked_cassettes); end
2109
+ end
2110
+ end
2111
+
2112
+ # An enumerable lazily wrapping a list of cassettes that a context is using
2113
+ #
2114
+ # source://vcr//lib/vcr/linked_cassette.rb#8
2115
+ class VCR::LinkedCassette::CassetteList
2116
+ include ::Enumerable
2117
+
2118
+ # Creates a new list of context-owned cassettes and linked cassettes
2119
+ #
2120
+ # @param cassettes [Array] context-owned cassettes
2121
+ # @param linked_cassettes [Array] context-unowned (linked) cassettes
2122
+ # @return [CassetteList] a new instance of CassetteList
2123
+ #
2124
+ # source://vcr//lib/vcr/linked_cassette.rb#14
2125
+ def initialize(cassettes, linked_cassettes); end
2126
+
2127
+ # Yields linked cassettes first, and then context-owned cassettes
2128
+ #
2129
+ # source://vcr//lib/vcr/linked_cassette.rb#20
2130
+ def each; end
2131
+
2132
+ # Provide last implementation, which is not provided by Enumerable
2133
+ #
2134
+ # source://vcr//lib/vcr/linked_cassette.rb#31
2135
+ def last; end
2136
+
2137
+ # Provide size implementation, which is not provided by Enumerable
2138
+ #
2139
+ # source://vcr//lib/vcr/linked_cassette.rb#40
2140
+ def size; end
2141
+
2142
+ protected
2143
+
2144
+ # source://vcr//lib/vcr/linked_cassette.rb#45
2145
+ def wrap(cassette); end
2146
+ end
2147
+
2148
+ # Provides log message formatting helper methods.
2149
+ #
2150
+ # @private
2151
+ #
2152
+ # source://vcr//lib/vcr/util/logger.rb#4
2153
+ class VCR::Logger
2154
+ # @return [Logger] a new instance of Logger
2155
+ #
2156
+ # source://vcr//lib/vcr/util/logger.rb#5
2157
+ def initialize(stream); end
2158
+
2159
+ # source://vcr//lib/vcr/util/logger.rb#9
2160
+ def log(message, log_prefix, indentation_level = T.unsafe(nil)); end
2161
+
2162
+ # source://vcr//lib/vcr/util/logger.rb#15
2163
+ def request_summary(request, request_matchers); end
2164
+
2165
+ # source://vcr//lib/vcr/util/logger.rb#22
2166
+ def response_summary(response); end
2167
+ end
2168
+
2169
+ # Provides common logger helper methods that simply delegate to
2170
+ # the underlying logger object.
2171
+ #
2172
+ # @private
2173
+ #
2174
+ # source://vcr//lib/vcr/util/logger.rb#45
2175
+ module VCR::Logger::Mixin
2176
+ # source://vcr//lib/vcr/util/logger.rb#46
2177
+ def log(message, indentation_level = T.unsafe(nil)); end
2178
+
2179
+ # source://vcr//lib/vcr/util/logger.rb#50
2180
+ def request_summary(*args); end
2181
+
2182
+ # source://vcr//lib/vcr/util/logger.rb#54
2183
+ def response_summary(*args); end
2184
+ end
2185
+
2186
+ # A null-object version of the Logger. Used when
2187
+ # a `debug_logger` has not been set.
2188
+ #
2189
+ # @note We used to use a null object for the `debug_logger` itself,
2190
+ # but some users noticed a negative perf impact from having the
2191
+ # logger formatting logic still executing in that case, so we
2192
+ # moved the null object interface up a layer to here.
2193
+ # @private
2194
+ #
2195
+ # source://vcr//lib/vcr/util/logger.rb#34
2196
+ module VCR::Logger::Null
2197
+ private
2198
+
2199
+ # source://vcr//lib/vcr/util/logger.rb#37
2200
+ def log(*_arg0); end
2201
+
2202
+ # source://vcr//lib/vcr/util/logger.rb#38
2203
+ def request_summary(*_arg0); end
2204
+
2205
+ # source://vcr//lib/vcr/util/logger.rb#39
2206
+ def response_summary(*_arg0); end
2207
+
2208
+ class << self
2209
+ # source://vcr//lib/vcr/util/logger.rb#37
2210
+ def log(*_arg0); end
2211
+
2212
+ # source://vcr//lib/vcr/util/logger.rb#38
2213
+ def request_summary(*_arg0); end
2214
+
2215
+ # source://vcr//lib/vcr/util/logger.rb#39
2216
+ def response_summary(*_arg0); end
2217
+ end
2218
+ end
2219
+
2220
+ # The main thread in which VCR was loaded
2221
+ #
2222
+ # source://vcr//lib/vcr.rb#30
2223
+ VCR::MainThread = T.let(T.unsafe(nil), Thread)
2224
+
2225
+ # Contains middlewares for use with different libraries.
2226
+ #
2227
+ # source://vcr//lib/vcr.rb#39
2228
+ module VCR::Middleware; end
2229
+
2230
+ # Object yielded by VCR's {Rack} middleware that allows you to configure
2231
+ # the cassette dynamically based on the rack env.
2232
+ #
2233
+ # source://vcr//lib/vcr/middleware/rack.rb#5
2234
+ class VCR::Middleware::CassetteArguments
2235
+ # @private
2236
+ # @return [CassetteArguments] a new instance of CassetteArguments
2237
+ #
2238
+ # source://vcr//lib/vcr/middleware/rack.rb#7
2239
+ def initialize; end
2240
+
2241
+ # Sets (and gets) the cassette name.
2242
+ #
2243
+ # @param name [#to_s] the cassette name
2244
+ # @return [#to_s] the cassette name
2245
+ #
2246
+ # source://vcr//lib/vcr/middleware/rack.rb#16
2247
+ def name(name = T.unsafe(nil)); end
2248
+
2249
+ # Sets (and gets) the cassette options.
2250
+ #
2251
+ # @param options [Hash] the cassette options
2252
+ # @return [Hash] the cassette options
2253
+ #
2254
+ # source://vcr//lib/vcr/middleware/rack.rb#25
2255
+ def options(options = T.unsafe(nil)); end
2256
+ end
2257
+
2258
+ # Faraday middleware that VCR uses to record and replay HTTP requests made through
2259
+ # Faraday.
2260
+ #
2261
+ # @note You can either insert this middleware into the Faraday middleware stack
2262
+ # yourself or configure {VCR::Configuration#hook_into} to hook into `:faraday`.
2263
+ #
2264
+ # source://vcr//lib/vcr/middleware/faraday.rb#15
2265
+ class VCR::Middleware::Faraday
2266
+ include ::VCR::Deprecations::Middleware::Faraday
2267
+
2268
+ # Constructs a new instance of the Faraday middleware.
2269
+ #
2270
+ # @param app [#call] the faraday app
2271
+ # @return [Faraday] a new instance of Faraday
2272
+ #
2273
+ # source://vcr//lib/vcr/middleware/faraday.rb#21
2274
+ def initialize(app); end
2275
+
2276
+ # Handles the HTTP request being made through Faraday
2277
+ #
2278
+ # @param env [Hash] the Faraday request env hash
2279
+ #
2280
+ # source://vcr//lib/vcr/middleware/faraday.rb#29
2281
+ def call(env); end
2282
+
2283
+ # Close any persistent connections.
2284
+ #
2285
+ # source://vcr//lib/vcr/middleware/faraday.rb#35
2286
+ def close; end
2287
+ end
2288
+
2289
+ # @private
2290
+ #
2291
+ # source://vcr//lib/vcr/middleware/faraday.rb#40
2292
+ class VCR::Middleware::Faraday::RequestHandler < ::VCR::RequestHandler
2293
+ # @return [RequestHandler] a new instance of RequestHandler
2294
+ #
2295
+ # source://vcr//lib/vcr/middleware/faraday.rb#42
2296
+ def initialize(app, env); end
2297
+
2298
+ # Returns the value of attribute app.
2299
+ #
2300
+ # source://vcr//lib/vcr/middleware/faraday.rb#41
2301
+ def app; end
2302
+
2303
+ # Returns the value of attribute env.
2304
+ #
2305
+ # source://vcr//lib/vcr/middleware/faraday.rb#41
2306
+ def env; end
2307
+
2308
+ # source://vcr//lib/vcr/middleware/faraday.rb#47
2309
+ def handle; end
2310
+
2311
+ private
2312
+
2313
+ # @return [Boolean]
2314
+ #
2315
+ # source://vcr//lib/vcr/middleware/faraday.rb#59
2316
+ def delay_finishing?; end
2317
+
2318
+ # source://vcr//lib/vcr/middleware/faraday.rb#120
2319
+ def invoke_after_request_hook(response); end
2320
+
2321
+ # source://vcr//lib/vcr/middleware/faraday.rb#92
2322
+ def on_ignored_request; end
2323
+
2324
+ # source://vcr//lib/vcr/middleware/faraday.rb#110
2325
+ def on_recordable_request; end
2326
+
2327
+ # source://vcr//lib/vcr/middleware/faraday.rb#98
2328
+ def on_stubbed_by_vcr_request; end
2329
+
2330
+ # source://vcr//lib/vcr/middleware/faraday.rb#71
2331
+ def raw_body_from(body); end
2332
+
2333
+ # source://vcr//lib/vcr/middleware/faraday.rb#79
2334
+ def response_for(response); end
2335
+
2336
+ # source://vcr//lib/vcr/middleware/faraday.rb#63
2337
+ def vcr_request; end
2338
+ end
2339
+
2340
+ # Rack middleware that uses a VCR cassette for each incoming HTTP request.
2341
+ #
2342
+ # @example
2343
+ # app = Rack::Builder.new do
2344
+ # use VCR::Middleware::Rack do |cassette, env|
2345
+ # cassette.name "rack/#{env['SERVER_NAME']}"
2346
+ # cassette.options :record => :new_episodes
2347
+ # end
2348
+ #
2349
+ # run MyRackApp
2350
+ # end
2351
+ # @note This will record/replay _outbound_ HTTP requests made by your rack app.
2352
+ #
2353
+ # source://vcr//lib/vcr/middleware/rack.rb#43
2354
+ class VCR::Middleware::Rack
2355
+ include ::VCR::VariableArgsBlockCaller
2356
+
2357
+ # Constructs a new instance of VCR's rack middleware.
2358
+ #
2359
+ # @param app [#call] the rack app
2360
+ # @raise [ArgumentError] if no configuration block is provided
2361
+ # @return [Rack] a new instance of Rack
2362
+ # @yield the cassette configuration block
2363
+ # @yieldparam cassette [CassetteArguments] the cassette configuration object
2364
+ # @yieldparam env [(optional) Hash] the rack env hash
2365
+ #
2366
+ # source://vcr//lib/vcr/middleware/rack.rb#53
2367
+ def initialize(app, &block); end
2368
+
2369
+ # Implements the rack middleware interface.
2370
+ #
2371
+ # @param env [Hash] the rack env hash
2372
+ # @return [Array(Integer, Hash, #each)] the rack response
2373
+ #
2374
+ # source://vcr//lib/vcr/middleware/rack.rb#62
2375
+ def call(env); end
2376
+
2377
+ private
2378
+
2379
+ # source://vcr//lib/vcr/middleware/rack.rb#72
2380
+ def cassette_arguments(env); end
2381
+ end
2382
+
2383
+ # @private
2384
+ #
2385
+ # source://vcr//lib/vcr/structs.rb#7
2386
+ module VCR::Normalizers; end
2387
+
2388
+ # @private
2389
+ #
2390
+ # source://vcr//lib/vcr/structs.rb#9
2391
+ module VCR::Normalizers::Body
2392
+ mixes_in_class_methods ::VCR::Normalizers::Body::ClassMethods
2393
+
2394
+ # source://vcr//lib/vcr/structs.rb#61
2395
+ def initialize(*args); end
2396
+
2397
+ private
2398
+
2399
+ # source://vcr//lib/vcr/structs.rb#92
2400
+ def base_body_hash(body); end
2401
+
2402
+ # source://vcr//lib/vcr/structs.rb#78
2403
+ def serializable_body; end
2404
+
2405
+ class << self
2406
+ # @private
2407
+ #
2408
+ # source://vcr//lib/vcr/structs.rb#10
2409
+ def included(klass); end
2410
+ end
2411
+ end
2412
+
2413
+ # @private
2414
+ #
2415
+ # source://vcr//lib/vcr/structs.rb#15
2416
+ module VCR::Normalizers::Body::ClassMethods
2417
+ # source://vcr//lib/vcr/structs.rb#16
2418
+ def body_from(hash_or_string); end
2419
+
2420
+ # source://vcr//lib/vcr/structs.rb#29
2421
+ def force_encode_string(string, encoding); end
2422
+
2423
+ # source://vcr//lib/vcr/structs.rb#34
2424
+ def try_encode_string(string, encoding); end
2425
+ end
2426
+
2427
+ # @private
2428
+ #
2429
+ # source://vcr//lib/vcr/structs.rb#103
2430
+ module VCR::Normalizers::Header
2431
+ # source://vcr//lib/vcr/structs.rb#104
2432
+ def initialize(*args); end
2433
+
2434
+ private
2435
+
2436
+ # source://vcr//lib/vcr/structs.rb#153
2437
+ def convert_to_raw_strings(array); end
2438
+
2439
+ # source://vcr//lib/vcr/structs.rb#146
2440
+ def delete_header(key); end
2441
+
2442
+ # source://vcr//lib/vcr/structs.rb#139
2443
+ def edit_header(key, value = T.unsafe(nil)); end
2444
+
2445
+ # source://vcr//lib/vcr/structs.rb#134
2446
+ def get_header(key); end
2447
+
2448
+ # source://vcr//lib/vcr/structs.rb#129
2449
+ def header_key(key); end
2450
+
2451
+ # source://vcr//lib/vcr/structs.rb#111
2452
+ def normalize_headers; end
2453
+ end
2454
+
2455
+ # @private
2456
+ #
2457
+ # source://vcr//lib/vcr/util/internet_connection.rb#8
2458
+ module VCR::Ping
2459
+ private
2460
+
2461
+ # source://vcr//lib/vcr/util/internet_connection.rb#9
2462
+ def pingecho(host, timeout = T.unsafe(nil), service = T.unsafe(nil)); end
2463
+
2464
+ class << self
2465
+ # source://vcr//lib/vcr/util/internet_connection.rb#9
2466
+ def pingecho(host, timeout = T.unsafe(nil), service = T.unsafe(nil)); end
2467
+ end
2468
+ end
2469
+
2470
+ # Integrates VCR with RSpec.
2471
+ #
2472
+ # source://vcr//lib/vcr.rb#35
2473
+ module VCR::RSpec; end
2474
+
2475
+ # @private
2476
+ #
2477
+ # source://vcr//lib/vcr/test_frameworks/rspec.rb#5
2478
+ module VCR::RSpec::Metadata
2479
+ extend ::VCR::RSpec::Metadata
2480
+
2481
+ # source://vcr//lib/vcr/test_frameworks/rspec.rb#30
2482
+ def configure!; end
2483
+
2484
+ # source://vcr//lib/vcr/test_frameworks/rspec.rb#8
2485
+ def vcr_cassette_name_for(metadata); end
2486
+ end
2487
+
2488
+ # The request of an {HTTPInteraction}.
2489
+ #
2490
+ # @attr method [Symbol] the HTTP method (i.e. :head, :options, :get, :post, :put, :patch or :delete)
2491
+ # @attr uri [String] the request URI
2492
+ # @attr body [String, nil] the request body
2493
+ # @attr headers [Hash{String => Array<String>}] the request headers
2494
+ #
2495
+ # source://vcr//lib/vcr/structs.rb#176
2496
+ class VCR::Request < ::Struct
2497
+ include ::VCR::Normalizers::Header
2498
+ include ::VCR::Normalizers::Body
2499
+ extend ::VCR::Normalizers::Body::ClassMethods
2500
+
2501
+ # @return [Request] a new instance of Request
2502
+ #
2503
+ # source://vcr//lib/vcr/structs.rb#180
2504
+ def initialize(*args); end
2505
+
2506
+ # the HTTP method (i.e. :head, :options, :get, :post, :put, :patch or :delete)
2507
+ #
2508
+ # @return [Symbol] the current value of method
2509
+ #
2510
+ # source://vcr//lib/vcr/structs.rb#228
2511
+ def method(*args); end
2512
+
2513
+ # Parses the URI using the configured `uri_parser`.
2514
+ #
2515
+ # @return [#schema, #host, #port, #path, #query] A parsed URI object.
2516
+ #
2517
+ # source://vcr//lib/vcr/structs.rb#223
2518
+ def parsed_uri; end
2519
+
2520
+ # Builds a serializable hash from the request data.
2521
+ #
2522
+ # @return [Hash] hash that represents this request and can be easily
2523
+ # serialized.
2524
+ # @see Request.from_hash
2525
+ #
2526
+ # source://vcr//lib/vcr/structs.rb#197
2527
+ def to_hash; end
2528
+
2529
+ private
2530
+
2531
+ # source://vcr//lib/vcr/structs.rb#315
2532
+ def without_standard_port(uri); end
2533
+
2534
+ class << self
2535
+ # Constructs a new instance from a hash.
2536
+ #
2537
+ # @param hash [Hash] the hash to use to construct the instance.
2538
+ # @return [Request] the request
2539
+ #
2540
+ # source://vcr//lib/vcr/structs.rb#210
2541
+ def from_hash(hash); end
2542
+ end
2543
+ end
2544
+
2545
+ # Provides fiber-awareness for the {VCR::Configuration#around_http_request} hook.
2546
+ #
2547
+ # source://vcr//lib/vcr/structs.rb#293
2548
+ class VCR::Request::FiberAware
2549
+ # Yields the fiber so the request can proceed.
2550
+ #
2551
+ # @return [VCR::Response] the response from the request
2552
+ #
2553
+ # source://vcr//lib/vcr/structs.rb#297
2554
+ def proceed; end
2555
+
2556
+ # Builds a proc that allows the request to proceed when called.
2557
+ # This allows you to treat the request as a proc and pass it on
2558
+ # to a method that yields (at which point the request will proceed).
2559
+ #
2560
+ # @return [Proc] the proc
2561
+ #
2562
+ # source://vcr//lib/vcr/structs.rb#306
2563
+ def to_proc; end
2564
+ end
2565
+
2566
+ # Decorates a {Request} with its current type.
2567
+ #
2568
+ # source://vcr//lib/vcr/structs.rb#234
2569
+ class VCR::Request::Typed
2570
+ # @param request [Request] the request
2571
+ # @param type [Symbol] the type. Should be one of `:ignored`, `:stubbed`, `:recordable` or `:unhandled`.
2572
+ # @return [Typed] a new instance of Typed
2573
+ #
2574
+ # source://vcr//lib/vcr/structs.rb#240
2575
+ def initialize(request, type); end
2576
+
2577
+ # @return [Boolean] whether or not this request is being stubbed by an
2578
+ # external library (such as WebMock).
2579
+ # @see #stubbed_by_vcr?
2580
+ # @see #stubbed?
2581
+ #
2582
+ # source://vcr//lib/vcr/structs.rb#261
2583
+ def externally_stubbed?; end
2584
+
2585
+ # @return [Boolean] whether or not this request is being ignored
2586
+ #
2587
+ # source://vcr//lib/vcr/structs.rb#246
2588
+ def ignored?; end
2589
+
2590
+ # @note VCR allows `:ignored` and `:recordable` requests to be made for real.
2591
+ # @return [Boolean] whether or not this request will be made for real.
2592
+ #
2593
+ # source://vcr//lib/vcr/structs.rb#277
2594
+ def real?; end
2595
+
2596
+ # @return [Boolean] whether or not this request will be recorded.
2597
+ #
2598
+ # source://vcr//lib/vcr/structs.rb#266
2599
+ def recordable?; end
2600
+
2601
+ # @return [Boolean] whether or not this request will be stubbed.
2602
+ # It may be stubbed by an external library or by VCR.
2603
+ # @see #stubbed_by_vcr?
2604
+ # @see #externally_stubbed?
2605
+ #
2606
+ # source://vcr//lib/vcr/structs.rb#285
2607
+ def stubbed?; end
2608
+
2609
+ # @return [Boolean] whether or not this request is being stubbed by VCR
2610
+ # @see #externally_stubbed?
2611
+ # @see #stubbed?
2612
+ #
2613
+ # source://vcr//lib/vcr/structs.rb#253
2614
+ def stubbed_by_vcr?; end
2615
+
2616
+ # @return [Symbol] One of `:ignored`, `:stubbed`, `:recordable` or `:unhandled`.
2617
+ #
2618
+ # source://vcr//lib/vcr/structs.rb#236
2619
+ def type; end
2620
+
2621
+ # @return [Boolean] whether or not VCR knows how to handle this request.
2622
+ #
2623
+ # source://vcr//lib/vcr/structs.rb#271
2624
+ def unhandled?; end
2625
+ end
2626
+
2627
+ # @private
2628
+ #
2629
+ # source://vcr//lib/vcr/request_handler.rb#3
2630
+ class VCR::RequestHandler
2631
+ include ::VCR::Logger::Mixin
2632
+
2633
+ # source://vcr//lib/vcr/request_handler.rb#6
2634
+ def handle; end
2635
+
2636
+ private
2637
+
2638
+ # @return [Boolean]
2639
+ #
2640
+ # source://vcr//lib/vcr/request_handler.rb#62
2641
+ def disabled?; end
2642
+
2643
+ # @return [Boolean]
2644
+ #
2645
+ # source://vcr//lib/vcr/request_handler.rb#54
2646
+ def externally_stubbed?; end
2647
+
2648
+ # @return [Boolean]
2649
+ #
2650
+ # source://vcr//lib/vcr/request_handler.rb#66
2651
+ def has_response_stub?(consume_stub); end
2652
+
2653
+ # source://vcr//lib/vcr/request_handler.rb#49
2654
+ def invoke_after_request_hook(vcr_response); end
2655
+
2656
+ # source://vcr//lib/vcr/request_handler.rb#43
2657
+ def invoke_before_request_hook; end
2658
+
2659
+ # source://vcr//lib/vcr/request_handler.rb#78
2660
+ def library_name; end
2661
+
2662
+ # source://vcr//lib/vcr/request_handler.rb#110
2663
+ def log_prefix; end
2664
+
2665
+ # Subclasses can implement these
2666
+ #
2667
+ # source://vcr//lib/vcr/request_handler.rb#84
2668
+ def on_externally_stubbed_request; end
2669
+
2670
+ # source://vcr//lib/vcr/request_handler.rb#87
2671
+ def on_ignored_request; end
2672
+
2673
+ # source://vcr//lib/vcr/request_handler.rb#93
2674
+ def on_recordable_request; end
2675
+
2676
+ # source://vcr//lib/vcr/request_handler.rb#90
2677
+ def on_stubbed_by_vcr_request; end
2678
+
2679
+ # @raise [VCR::Errors::UnhandledHTTPRequestError]
2680
+ #
2681
+ # source://vcr//lib/vcr/request_handler.rb#96
2682
+ def on_unhandled_request; end
2683
+
2684
+ # source://vcr//lib/vcr/request_handler.rb#100
2685
+ def request_summary; end
2686
+
2687
+ # source://vcr//lib/vcr/request_handler.rb#33
2688
+ def request_type(consume_stub = T.unsafe(nil)); end
2689
+
2690
+ # source://vcr//lib/vcr/request_handler.rb#29
2691
+ def set_typed_request_for_after_hook(request_type); end
2692
+
2693
+ # @return [Boolean]
2694
+ #
2695
+ # source://vcr//lib/vcr/request_handler.rb#58
2696
+ def should_ignore?; end
2697
+
2698
+ # source://vcr//lib/vcr/request_handler.rb#74
2699
+ def stubbed_response; end
2700
+ end
2701
+
2702
+ # @private
2703
+ #
2704
+ # source://vcr//lib/vcr/request_ignorer.rb#6
2705
+ class VCR::RequestIgnorer
2706
+ include ::VCR::VariableArgsBlockCaller
2707
+ include ::VCR::Hooks
2708
+ include ::VCR::RequestIgnorer::DefinedHooks
2709
+ extend ::VCR::Hooks::ClassMethods
2710
+
2711
+ # @return [RequestIgnorer] a new instance of RequestIgnorer
2712
+ #
2713
+ # source://vcr//lib/vcr/request_ignorer.rb#13
2714
+ def initialize; end
2715
+
2716
+ # @return [Boolean]
2717
+ #
2718
+ # source://vcr//lib/vcr/request_ignorer.rb#40
2719
+ def ignore?(request); end
2720
+
2721
+ # source://vcr//lib/vcr/request_ignorer.rb#32
2722
+ def ignore_hosts(*hosts); end
2723
+
2724
+ # source://vcr//lib/vcr/request_ignorer.rb#20
2725
+ def ignore_localhost=(value); end
2726
+
2727
+ # @return [Boolean]
2728
+ #
2729
+ # source://vcr//lib/vcr/request_ignorer.rb#28
2730
+ def localhost_ignored?; end
2731
+
2732
+ # source://vcr//lib/vcr/request_ignorer.rb#36
2733
+ def unignore_hosts(*hosts); end
2734
+
2735
+ private
2736
+
2737
+ # source://vcr//lib/vcr/request_ignorer.rb#46
2738
+ def ignored_hosts; end
2739
+ end
2740
+
2741
+ # source://vcr//lib/vcr/request_ignorer.rb#0
2742
+ module VCR::RequestIgnorer::DefinedHooks
2743
+ # source://vcr//lib/vcr/util/hooks.rb#55
2744
+ def ignore_request(*filters, &hook); end
2745
+ end
2746
+
2747
+ # source://vcr//lib/vcr/request_ignorer.rb#11
2748
+ VCR::RequestIgnorer::LOCALHOST_ALIASES = T.let(T.unsafe(nil), Array)
2749
+
2750
+ # Keeps track of the different request matchers.
2751
+ #
2752
+ # source://vcr//lib/vcr/request_matcher_registry.rb#5
2753
+ class VCR::RequestMatcherRegistry
2754
+ # @private
2755
+ # @return [RequestMatcherRegistry] a new instance of RequestMatcherRegistry
2756
+ #
2757
+ # source://vcr//lib/vcr/request_matcher_registry.rb#49
2758
+ def initialize; end
2759
+
2760
+ # @private
2761
+ #
2762
+ # source://vcr//lib/vcr/request_matcher_registry.rb#64
2763
+ def [](matcher); end
2764
+
2765
+ # @private
2766
+ #
2767
+ # source://vcr//lib/vcr/request_matcher_registry.rb#55
2768
+ def register(name, &block); end
2769
+
2770
+ # Builds a dynamic request matcher that matches on a URI while ignoring the
2771
+ # named query parameters. This is useful for dealing with non-deterministic
2772
+ # URIs (i.e. that have a timestamp or request signature parameter).
2773
+ #
2774
+ # @example
2775
+ # without_timestamp = VCR.request_matchers.uri_without_param(:timestamp)
2776
+ #
2777
+ # # use it directly...
2778
+ # VCR.use_cassette('example', :match_requests_on => [:method, without_timestamp]) { }
2779
+ #
2780
+ # # ...or register it as a named matcher
2781
+ # VCR.configure do |c|
2782
+ # c.register_request_matcher(:uri_without_timestamp, &without_timestamp)
2783
+ # end
2784
+ #
2785
+ # VCR.use_cassette('example', :match_requests_on => [:method, :uri_without_timestamp]) { }
2786
+ # @param ignores [Array<#to_s>] The names of the query parameters to ignore
2787
+ # @return [#call] the request matcher
2788
+ #
2789
+ # source://vcr//lib/vcr/request_matcher_registry.rb#91
2790
+ def uri_without_param(*ignores); end
2791
+
2792
+ # Builds a dynamic request matcher that matches on a URI while ignoring the
2793
+ # named query parameters. This is useful for dealing with non-deterministic
2794
+ # URIs (i.e. that have a timestamp or request signature parameter).
2795
+ #
2796
+ # @example
2797
+ # without_timestamp = VCR.request_matchers.uri_without_param(:timestamp)
2798
+ #
2799
+ # # use it directly...
2800
+ # VCR.use_cassette('example', :match_requests_on => [:method, without_timestamp]) { }
2801
+ #
2802
+ # # ...or register it as a named matcher
2803
+ # VCR.configure do |c|
2804
+ # c.register_request_matcher(:uri_without_timestamp, &without_timestamp)
2805
+ # end
2806
+ #
2807
+ # VCR.use_cassette('example', :match_requests_on => [:method, :uri_without_timestamp]) { }
2808
+ # @param ignores [Array<#to_s>] The names of the query parameters to ignore
2809
+ # @return [#call] the request matcher
2810
+ #
2811
+ # source://vcr//lib/vcr/request_matcher_registry.rb#91
2812
+ def uri_without_params(*ignores); end
2813
+
2814
+ private
2815
+
2816
+ # source://vcr//lib/vcr/request_matcher_registry.rb#105
2817
+ def raise_unregistered_matcher_error(name); end
2818
+
2819
+ # source://vcr//lib/vcr/request_matcher_registry.rb#111
2820
+ def register_built_ins; end
2821
+
2822
+ # source://vcr//lib/vcr/request_matcher_registry.rb#132
2823
+ def try_to_register_body_as_json; end
2824
+
2825
+ # source://vcr//lib/vcr/request_matcher_registry.rb#98
2826
+ def uri_without_param_matchers; end
2827
+ end
2828
+
2829
+ # The default request matchers used for any cassette that does not
2830
+ # specify request matchers.
2831
+ #
2832
+ # source://vcr//lib/vcr/request_matcher_registry.rb#9
2833
+ VCR::RequestMatcherRegistry::DEFAULT_MATCHERS = T.let(T.unsafe(nil), Array)
2834
+
2835
+ # @private
2836
+ #
2837
+ # source://vcr//lib/vcr/request_matcher_registry.rb#12
2838
+ class VCR::RequestMatcherRegistry::Matcher < ::Struct
2839
+ # @return [Boolean]
2840
+ #
2841
+ # source://vcr//lib/vcr/request_matcher_registry.rb#13
2842
+ def matches?(request_1, request_2); end
2843
+ end
2844
+
2845
+ # @private
2846
+ #
2847
+ # source://vcr//lib/vcr/request_matcher_registry.rb#19
2848
+ class VCR::RequestMatcherRegistry::URIWithoutParamsMatcher < ::Struct
2849
+ # source://vcr//lib/vcr/request_matcher_registry.rb#39
2850
+ def call(request_1, request_2); end
2851
+
2852
+ # source://vcr//lib/vcr/request_matcher_registry.rb#20
2853
+ def partial_uri_from(request); end
2854
+
2855
+ # source://vcr//lib/vcr/request_matcher_registry.rb#43
2856
+ def to_proc; end
2857
+ end
2858
+
2859
+ # The response of an {HTTPInteraction}.
2860
+ #
2861
+ # @attr status [ResponseStatus] the status of the response
2862
+ # @attr headers [Hash{String => Array<String>}] the response headers
2863
+ # @attr body [String] the response body
2864
+ # @attr http_version [nil, String] the HTTP version
2865
+ # @attr adapter_metadata [Hash] Additional metadata used by a specific VCR adapter.
2866
+ #
2867
+ # source://vcr//lib/vcr/structs.rb#331
2868
+ class VCR::Response < ::Struct
2869
+ include ::VCR::Normalizers::Header
2870
+ include ::VCR::Normalizers::Body
2871
+ extend ::VCR::Normalizers::Body::ClassMethods
2872
+
2873
+ # @return [Response] a new instance of Response
2874
+ #
2875
+ # source://vcr//lib/vcr/structs.rb#335
2876
+ def initialize(*args); end
2877
+
2878
+ # Checks if the type of encoding is one of "gzip" or "deflate".
2879
+ #
2880
+ # @return [Boolean]
2881
+ #
2882
+ # source://vcr//lib/vcr/structs.rb#382
2883
+ def compressed?; end
2884
+
2885
+ # The type of encoding.
2886
+ #
2887
+ # @return [String] encoding type
2888
+ #
2889
+ # source://vcr//lib/vcr/structs.rb#377
2890
+ def content_encoding; end
2891
+
2892
+ # Decodes the compressed body and deletes evidence that it was ever compressed.
2893
+ #
2894
+ # @raise [VCR::Errors::UnknownContentEncodingError] if the content encoding
2895
+ # is not a known encoding.
2896
+ # @return self
2897
+ #
2898
+ # source://vcr//lib/vcr/structs.rb#396
2899
+ def decompress; end
2900
+
2901
+ # Recompresses the decompressed body according to adapter metadata.
2902
+ #
2903
+ # @raise [VCR::Errors::UnknownContentEncodingError] if the content encoding
2904
+ # stored in the adapter metadata is unknown
2905
+ #
2906
+ # source://vcr//lib/vcr/structs.rb#410
2907
+ def recompress; end
2908
+
2909
+ # Builds a serializable hash from the response data.
2910
+ #
2911
+ # @return [Hash] hash that represents this response
2912
+ # and can be easily serialized.
2913
+ # @see Response.from_hash
2914
+ #
2915
+ # source://vcr//lib/vcr/structs.rb#345
2916
+ def to_hash; end
2917
+
2918
+ # Updates the Content-Length response header so that it is
2919
+ # accurate for the response body.
2920
+ #
2921
+ # source://vcr//lib/vcr/structs.rb#370
2922
+ def update_content_length_header; end
2923
+
2924
+ # Checks if VCR decompressed the response body
2925
+ #
2926
+ # @return [Boolean]
2927
+ #
2928
+ # source://vcr//lib/vcr/structs.rb#387
2929
+ def vcr_decompressed?; end
2930
+
2931
+ class << self
2932
+ # Decode string compressed with gzip or deflate
2933
+ #
2934
+ # @raise [VCR::Errors::UnknownContentEncodingError] if the content encoding
2935
+ # is not a known encoding.
2936
+ #
2937
+ # source://vcr//lib/vcr/structs.rb#449
2938
+ def decompress(body, type); end
2939
+
2940
+ # Constructs a new instance from a hash.
2941
+ #
2942
+ # @param hash [Hash] the hash to use to construct the instance.
2943
+ # @return [Response] the response
2944
+ #
2945
+ # source://vcr//lib/vcr/structs.rb#360
2946
+ def from_hash(hash); end
2947
+ end
2948
+ end
2949
+
2950
+ # source://vcr//lib/vcr/structs.rb#440
2951
+ VCR::Response::HAVE_ZLIB = T.let(T.unsafe(nil), TrueClass)
2952
+
2953
+ # The response status of an {HTTPInteraction}.
2954
+ #
2955
+ # @attr code [Integer] the HTTP status code
2956
+ # @attr message [String] the HTTP status message (e.g. "OK" for a status of 200)
2957
+ #
2958
+ # source://vcr//lib/vcr/structs.rb#475
2959
+ class VCR::ResponseStatus < ::Struct
2960
+ # Builds a serializable hash from the response status data.
2961
+ #
2962
+ # @return [Hash] hash that represents this response status
2963
+ # and can be easily serialized.
2964
+ # @see ResponseStatus.from_hash
2965
+ #
2966
+ # source://vcr//lib/vcr/structs.rb#481
2967
+ def to_hash; end
2968
+
2969
+ class << self
2970
+ # Constructs a new instance from a hash.
2971
+ #
2972
+ # @param hash [Hash] the hash to use to construct the instance.
2973
+ # @return [ResponseStatus] the response status
2974
+ #
2975
+ # source://vcr//lib/vcr/structs.rb#491
2976
+ def from_hash(hash); end
2977
+ end
2978
+ end
2979
+
2980
+ # @private
2981
+ #
2982
+ # source://vcr//lib/vcr/util/variable_args_block_caller.rb#3
2983
+ module VCR::VariableArgsBlockCaller
2984
+ # source://vcr//lib/vcr/util/variable_args_block_caller.rb#4
2985
+ def call_block(block, *args); end
2986
+ end
2987
+
2988
+ # @private
2989
+ #
2990
+ # source://vcr//lib/vcr/util/version_checker.rb#3
2991
+ class VCR::VersionChecker
2992
+ # @return [VersionChecker] a new instance of VersionChecker
2993
+ #
2994
+ # source://vcr//lib/vcr/util/version_checker.rb#4
2995
+ def initialize(library_name, library_version, min_version); end
2996
+
2997
+ # source://vcr//lib/vcr/util/version_checker.rb#13
2998
+ def check_version!; end
2999
+
3000
+ private
3001
+
3002
+ # source://vcr//lib/vcr/util/version_checker.rb#29
3003
+ def compare_version; end
3004
+
3005
+ # source://vcr//lib/vcr/util/version_checker.rb#43
3006
+ def parse_version(version); end
3007
+
3008
+ # @raise [Errors::LibraryVersionTooLowError]
3009
+ #
3010
+ # source://vcr//lib/vcr/util/version_checker.rb#23
3011
+ def raise_too_low_error; end
3012
+
3013
+ # @return [Boolean]
3014
+ #
3015
+ # source://vcr//lib/vcr/util/version_checker.rb#19
3016
+ def too_low?; end
3017
+
3018
+ # source://vcr//lib/vcr/util/version_checker.rb#39
3019
+ def version_requirement; end
3020
+ end