class FlexMock::HashMatcher

Match only things where the block evaluates to true.

Public Instance Methods

===(target) click to toggle source
# File lib/flexmock/argument_matchers.rb, line 62
def ===(target)
  @hash.all? { |k, v| target[k] == v }
end
inspect() click to toggle source
# File lib/flexmock/argument_matchers.rb, line 65
def inspect
  "hsh(#{@hash.inspect})"
end

Public Class Methods

new(hash) click to toggle source
# File lib/flexmock/argument_matchers.rb, line 59
def initialize(hash)
  @hash = hash
end