Class: RSpec::Matchers::BuiltIn::NegativeOperatorMatcher
- Inherits:
-
OperatorMatcher
- Object
- OperatorMatcher
- RSpec::Matchers::BuiltIn::NegativeOperatorMatcher
- Defined in:
- lib/rspec/matchers/operator_matcher.rb
Instance Method Summary (collapse)
Methods inherited from OperatorMatcher
#description, #fail_with_message, get, #initialize, register, registry, unregister, use_custom_matcher_or_delegate, #uses_generic_implementation_of?
Constructor Details
This class inherits a constructor from RSpec::Matchers::OperatorMatcher
Instance Method Details
- (Object) __delegate_operator(actual, operator, expected)
106 107 108 109 |
# File 'lib/rspec/matchers/operator_matcher.rb', line 106 def __delegate_operator(actual, operator, expected) return false unless actual.__send__(operator, expected) return ("expected not: #{operator} #{expected.inspect}\n got: #{operator.gsub(/./, ' ')} #{actual.inspect}") end |