class VCR::Response

Public Class Methods

from_net_http_response(response) click to toggle source
# File lib/vcr/structs/response.rb, line 6
def self.from_net_http_response(response)
  new(
    ResponseStatus.from_net_http_response(response),
    response.to_hash,
    response.body,
    response.http_version
  )
end

Public Instance Methods

update_content_length_header() click to toggle source
# File lib/vcr/structs/response.rb, line 15
def update_content_length_header
  headers['content-length'] &&= [body.length.to_s]
end