Class: VerifiedDouble::RecordedMethodSignatureRegistry

Inherits:
Array
  • Object
show all
Defined in:
lib/verified_double/recorded_method_signature_registry.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#current_doubleObject

Returns the value of attribute current_double.



3
4
5
# File 'lib/verified_double/recorded_method_signature_registry.rb', line 3

def current_double
  @current_double
end

Instance Method Details

#add_method_signature(a_double, method) ⇒ Object



5
6
7
8
# File 'lib/verified_double/recorded_method_signature_registry.rb', line 5

def add_method_signature(a_double, method)
  simple_double = SimpleDouble.new(a_double)
  self << simple_double.build_recorded_method_signature(method)
end

#add_method_signature_with_current_double(method) ⇒ Object



10
11
12
# File 'lib/verified_double/recorded_method_signature_registry.rb', line 10

def add_method_signature_with_current_double(method)
  add_method_signature(current_double, method)
end