Base
Parameter matcher which allows optional parameters to be specified.
@private
# File lib/mocha/parameter_matchers/optionally.rb, line 48 def matches?(available_parameters) index = 0 while (available_parameters.length > 0) && (index < @matchers.length) do matcher = @matchers[index] return false unless matcher.matches?(available_parameters) index += 1 end return true end # @private def mocha_inspect "optionally(#{@matchers.map { |matcher| matcher.mocha_inspect }.join(", ") })" end end
Generated with the Darkfish Rdoc Generator 2.