Class: Ramcrest::Is::Matcher
- Inherits:
-
Object
- Object
- Ramcrest::Is::Matcher
- Includes:
- Matcher
- Defined in:
- lib/ramcrest/is.rb
Instance Method Summary collapse
- #description ⇒ Object
-
#initialize(expected, was_originally_matcher) ⇒ Matcher
constructor
A new instance of Matcher.
- #mismatch_message(actual, match) ⇒ Object
Methods included from Matcher
#do_match, #matches?, #mismatch, #success
Constructor Details
#initialize(expected, was_originally_matcher) ⇒ Matcher
Returns a new instance of Matcher.
19 20 21 22 |
# File 'lib/ramcrest/is.rb', line 19 def initialize(expected, was_originally_matcher) @expected = expected @was_originally_matcher = was_originally_matcher end |
Instance Method Details
#description ⇒ Object
28 29 30 |
# File 'lib/ramcrest/is.rb', line 28 def description "is #{show @expected.description}" end |
#mismatch_message(actual, match) ⇒ Object
24 25 26 |
# File 'lib/ramcrest/is.rb', line 24 def (actual, match) "was #{show match.description}" end |