class RSpec::Mocks::MethodDouble

def define_proxy_method

Other tags:
    Private: -
def define_proxy_method
  return if @method_is_proxied
  object_singleton_class.class_eval <<-EOF, __FILE__, __LINE__ + 1
    def #{@method_name}(*args, &block)
      ::RSpec::Mocks.proxy_for(self).message_received :#{@method_name}, *args, &block
    end
    #{visibility_for_method}
  EOF
  @method_is_proxied = true
end