Class: Mocha::Expectation

Inherits:
Object
  • Object
show all
Defined in:
lib/bourne/expectation.rb

Overview

Extends Mocha::Expectation to record the full arguments and count whenver a stubbed or mocked method is invoked.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#invocation_countObject

:nodoc:



7
8
9
# File 'lib/bourne/expectation.rb', line 7

def invocation_count
  @invocation_count
end

Instance Method Details

#invoke_with_args(args, &block) ⇒ Object Also known as: invoke



9
10
11
12
# File 'lib/bourne/expectation.rb', line 9

def invoke_with_args(args, &block)
  Mockery.instance.invocation(@mock, method_name, args)
  invoke_without_args(&block)
end