Module: Sinclair::Matchers::MethodTo Private
- Included in:
- AddMethodTo, ChangeMethodOn
- Defined in:
- lib/sinclair/matchers/method_to.rb
Overview
This module is part of a private API. You should avoid using this module if possible, as it may be removed or be changed in the future.
Common methods on final matchers
Instance Method Summary collapse
-
#failure_message ⇒ String
private
Used for other versions of rspec.
-
#failure_message_when_negated ⇒ String
private
Used for other versions of rspec.
-
#matches?(event_proc) ⇒ Boolean
private
Checks if expectation is true or not.
Instance Method Details
#failure_message ⇒ String
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Used for other versions of rspec
Some versions call failure_message, others call failure_message_for_should
15 16 17 |
# File 'lib/sinclair/matchers/method_to.rb', line 15 def end |
#failure_message_when_negated ⇒ String
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Used for other versions of rspec
Some versions call failure_message_when_negated, others call failure_message_for_should_not
25 26 27 |
# File 'lib/sinclair/matchers/method_to.rb', line 25 def end |
#matches?(event_proc) ⇒ Boolean
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Checks if expectation is true or not
32 33 34 35 36 37 38 |
# File 'lib/sinclair/matchers/method_to.rb', line 32 def matches?(event_proc) return false unless event_proc.is_a?(Proc) raise_block_syntax_error if block_given? perform_change(event_proc) check end |