lib/bacon-expect/matchers/respond_to.rb in bacon-expect-1.0.2 vs lib/bacon-expect/matchers/respond_to.rb in bacon-expect-1.0.3
- old
+ new
@@ -19,10 +19,10 @@
valid &&= subject.respond_to?(@method_name)
valid &&= subject.method(@method_name).arity == @number_of_args if valid && @number_of_args
valid
end
- def fail!(subject)
- raise FailedExpectation.new("\"#{subject}\" expected to respond_to? #{@method_name}")
+ def fail!(subject, negated)
+ raise FailedExpectation.new(FailMessageRenderer.message_for_respond_to(negated, subject, @method_name, @number_of_args))
end
end
end; end
\ No newline at end of file