Method: Spec::Mocks::Proxy#initialize
- Defined in:
- lib/spec/mocks/proxy.rb
#initialize(target, name = nil, options = {}) ⇒ Proxy
Returns a new instance of Proxy.
18 19 20 21 22 23 24 25 26 27 28 29 |
# File 'lib/spec/mocks/proxy.rb', line 18 def initialize(target, name=nil, ={}) @target = target @name = name @error_generator = ErrorGenerator.new target, name, @expectation_ordering = OrderGroup.new @error_generator @expectations = [] @messages_received = [] @stubs = [] @proxied_methods = [] @options = ? DEFAULT_OPTIONS.dup.merge() : DEFAULT_OPTIONS @already_proxied_respond_to = false end |