Parent

Methods

Files

Mocha::ArgumentIterator

Public Class Methods

new(argument) click to toggle source
# File lib/mocha/argument_iterator.rb, line 5
def initialize(argument)
  @argument = argument
end

Public Instance Methods

each(&block) click to toggle source
# File lib/mocha/argument_iterator.rb, line 9
def each(&block)
  if @argument.is_a?(Hash) then
    @argument.each do |method_name, return_value|
      block.call(method_name, return_value)
    end
  else
    block.call(@argument)
  end
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.