Class: Minicrest::EndsWith
- Inherits:
-
StringMatcher
- Object
- Matcher
- StringMatcher
- Minicrest::EndsWith
- Defined in:
- lib/minicrest/ends_with.rb
Overview
Matcher that checks if a string ends with a given suffix.
Instance Method Summary collapse
-
#initialize(suffix) ⇒ EndsWith
constructor
Creates a new ends_with matcher.
Methods inherited from StringMatcher
#description, #failure_message, #matches?, #negated_failure_message
Methods inherited from Matcher
#&, #description, #failure_message, #matches?, #negated_failure_message, #|
Constructor Details
#initialize(suffix) ⇒ EndsWith
Creates a new ends_with matcher.
16 17 18 |
# File 'lib/minicrest/ends_with.rb', line 16 def initialize(suffix) super(suffix, :end_with?, 'end with') end |