Class: XSpec::AssertionContext::Doubles::Recorder

Inherits:
Object
  • Object
show all
Defined in:
lib/xspec/assertion_contexts.rb

Instance Method Summary collapse

Constructor Details

#initialize(double) ⇒ Recorder

Returns a new instance of Recorder.



169
170
171
# File 'lib/xspec/assertion_contexts.rb', line 169

def initialize(double)
  @double = double
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(*args, &ret) ⇒ Object



173
174
175
# File 'lib/xspec/assertion_contexts.rb', line 173

def method_missing(*args, &ret)
  @double._expect(args, &(ret || ->{}))
end