Class: Restspec::HeaderTests::EqualsTest

Inherits:
Struct
  • Object
show all
Defined in:
lib/restspec/rspec/matchers/have_header.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#expected_header_valueObject

Returns the value of attribute expected_header_value

Returns:

  • (Object)

    the current value of expected_header_value


30
31
32
# File 'lib/restspec/rspec/matchers/have_header.rb', line 30

def expected_header_value
  @expected_header_value
end

Instance Method Details

#perform(key, headers) ⇒ Object


31
32
33
# File 'lib/restspec/rspec/matchers/have_header.rb', line 31

def perform(key, headers)
  headers.fetch(key) == expected_header_value
end