Module: VCR::LibraryHooks::Excon

Defined in:
lib/vcr/library_hooks/excon.rb

Class Method Summary collapse

Class Method Details

.configure_middlewareObject



7
8
9
10
11
12
13
# File 'lib/vcr/library_hooks/excon.rb', line 7

def self.configure_middleware
  middlewares = ::Excon.defaults[:middlewares]

  middlewares << VCR::Middleware::Excon::Request
  response_parser_index = middlewares.index(::Excon::Middleware::ResponseParser)
  middlewares.insert(response_parser_index + 1, VCR::Middleware::Excon::Response)
end