method
__delegate_operator
__delegate_operator(actual, operator, expected)
public
Hide source
# File lib/spec/matchers/operator_matcher.rb, line 57 def __delegate_operator(actual, operator, expected) return true if actual.__send__(operator, expected) if ['==','===', '=~'].include?(operator) fail_with_message("expected: #{expected.inspect},\n got: #{actual.inspect} (using #{operator})") else fail_with_message("expected: #{operator} #{expected.inspect},\n got: #{operator.gsub(/./, ' ')} #{actual.inspect}") end end