Base
Parameter matcher which combines a number of other matchers using a logical AND.
@private
# File lib/mocha/parameter_matchers/all_of.rb, line 33 def initialize(*matchers) @matchers = matchers end
# File lib/mocha/parameter_matchers/all_of.rb, line 38 def matches?(available_parameters) parameter = available_parameters.shift @matchers.all? { |matcher| matcher.to_matcher.matches?([parameter]) } end
# File lib/mocha/parameter_matchers/all_of.rb, line 44 def mocha_inspect "all_of(#{@matchers.map { |matcher| matcher.mocha_inspect }.join(", ") })" end
[Validate]
Generated with the Darkfish Rdoc Generator 2.