Class: SuperDiff::EqualityMatchers::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/super_diff/equality_matchers/base.rb

Class Method Summary collapse

Instance Method Summary collapse

Class Method Details

.applies_to?(_value) ⇒ Boolean

Returns:

  • (Boolean)

Raises:

  • (NotImplementedError)


6
7
8
# File 'lib/super_diff/equality_matchers/base.rb', line 6

def self.applies_to?(_value)
  raise NotImplementedError
end

Instance Method Details

#callObject



21
22
23
24
25
26
27
# File 'lib/super_diff/equality_matchers/base.rb', line 21

def call
  if expected == actual # rubocop:disable Style/GuardClause `fail` is not Kernel#fail
    ''
  else
    fail
  end
end