Class: SuperDiff::RSpec::Differs::PartialHash

Inherits:
Differs::Hash show all
Defined in:
lib/super_diff/rspec/differs/partial_hash.rb

Class Method Summary collapse

Methods inherited from Differs::Hash

#call

Methods inherited from Differs::Base

#call

Class Method Details

.applies_to?(expected, actual) ⇒ Boolean

Returns:

  • (Boolean)


5
6
7
# File 'lib/super_diff/rspec/differs/partial_hash.rb', line 5

def self.applies_to?(expected, actual)
  SuperDiff::RSpec.partial_hash?(expected) && actual.is_a?(::Hash)
end