lib/rspec/sleeping_king_studios/matchers/shared/match_property.rb
# Checks whether the value of the predicate matches the expected value. If
# the value looks like an RSpec matcher (it responds to :matches?), runs
# value.matches?(); otherwise checks for equality using :==.
#
# @return [Boolean] true if the value matches the expected value; otherwise
#   false.
Checks whether the value of the predicate matches the expected value. If
the value looks like an RSpec matcher (it responds to :matches?), runs
value.matches?(); otherwise checks for equality using :==.
Checks whether the value of the predicate matches the expected value . If the value looks like an RSpec matcher ( it responds to : matches? ) runs value . matches? () ; otherwise checks for equality using : == .
def matches_predicate_value?
      return false unless responds_to_predicate?
      return true  unless @value_set
      actual_value = @actual.send(:"#{@expected}?")
      @matches_predicate_value = (@value.respond_to?(:matches?) && @value.respond_to?(:description)) ?
        @value.matches?(actual_value) :
        @value == actual_value
    end
def matches_predicate_value? return false unless responds_to_predicate? return true unless @value_set actual_value = @actual . send ( :" #{ @expected } ? " ) @matches_predicate_value = ( @value . respond_to? ( :matches? ) && @value . respond_to? ( :description ) ) ? @value . matches? ( actual_value ) : @value == actual_value end
Checks whether the value of the predicate matches the expected value.
Checks whether the value of the predicate matches the expected value .
true if the value matches the expected value; otherwise false.
true if the value matches the expected value ; otherwise false .
Boolean