class Shoulda::Matchers::Doublespeak::ObjectDouble
@private
def calls_to(method_name)
def calls_to(method_name) @calls_by_method_name[method_name] || [] end
def initialize
def initialize @calls = [] @calls_by_method_name = {} end
def method_missing(method_name, *args, &block)
def method_missing(method_name, *args, &block) call = MethodCall.new( method_name: method_name, args: args, block: block, caller: ::Kernel.caller ) calls << call (calls_by_method_name[method_name] ||= []) << call nil end
def respond_to?(name, include_private = nil)
def respond_to?(name, include_private = nil) true end