Class: RSpecJSONAPISerializer::Matchers::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/rspec_jsonapi_serializer/matchers/base.rb

Instance Method Summary collapse

Constructor Details

#initialize(expected) ⇒ Base

Returns a new instance of Base.



6
7
8
9
# File 'lib/rspec_jsonapi_serializer/matchers/base.rb', line 6

def initialize(expected)
  @expected    = expected
  @submatchers = []
end

Instance Method Details

#failure_messageObject

Raises:

  • (NotImplementedError)


15
16
17
# File 'lib/rspec_jsonapi_serializer/matchers/base.rb', line 15

def failure_message
  raise NotImplementedError
end

#failure_message_when_negatedObject

Raises:

  • (NotImplementedError)


19
20
21
# File 'lib/rspec_jsonapi_serializer/matchers/base.rb', line 19

def failure_message_when_negated
  raise NotImplementedError
end

#matches?(serializer_instance) ⇒ Boolean

Returns:

  • (Boolean)

Raises:

  • (NotImplementedError)


11
12
13
# File 'lib/rspec_jsonapi_serializer/matchers/base.rb', line 11

def matches?(serializer_instance)
  raise NotImplementedError
end