Flowdock
method

matches?

Importance_0
RSpec latest stable (1.3.1) - 0 notes - Class: Spec::Matchers::BePredicate
matches?(actual) public

No documentation

This method has no description. You can help the RSpec community by adding new notes.

Hide source
# File lib/spec/matchers/be.rb, line 128
      def matches?(actual)
        @actual = actual
        begin
          return @result = actual.__send__(predicate, *@args, &@block)
        rescue NameError => predicate_missing_error
          "this needs to be here or rcov will not count this branch even though it's executed in a code example"
        end

        begin
          return @result = actual.__send__(present_tense_predicate, *@args, &@block)
        rescue NameError
          raise predicate_missing_error
        end
      end
Register or log in to add new notes.