lib/rspec/matchers/built_in/exist.rb in rspec-expectations-2.12.1 vs lib/rspec/matchers/built_in/exist.rb in rspec-expectations-2.13.0

- old
+ new

@@ -7,10 +7,10 @@ end def matches?(actual) @actual = actual predicates = [:exist?, :exists?].select { |p| @actual.respond_to?(p) } - existence_values = predicates.map { |p| @actual.send(p, *@expected) } + existence_values = predicates.map { |p| @actual.__send__(p, *@expected) } uniq_truthy_values = existence_values.map { |v| !!v }.uniq case uniq_truthy_values.size when 0; raise NoMethodError.new("#{@actual.inspect} does not respond to either #exist? or #exists?") when 1; existence_values.first