Class: TestHeaders

Inherits:
Object
  • Object
show all
Includes:
ApiClients
Defined in:
lib/stitches/spec/test_headers.rb

Instance Method Summary collapse

Methods included from ApiClients

#api_client

Constructor Details

#initialize(options = {}) ⇒ TestHeaders

Returns a new instance of TestHeaders.



3
4
5
6
7
8
9
10
11
# File 'lib/stitches/spec/test_headers.rb', line 3

def initialize(options={})
  full_mimetype = mime_type(options)
  @headers = {
    "Accept"       => full_mimetype,
    "Content-Type" => full_mimetype,
  }.tap { |headers|
    set_authorization_header(headers,options) unless Stitches.configuration.disable_api_key_support
  }
end

Instance Method Details

#headersObject



13
14
15
# File 'lib/stitches/spec/test_headers.rb', line 13

def headers
  @headers
end