Class: RSpec::Mocks::AnyInstance::Chain

Inherits:
Object
  • Object
show all
Defined in:
lib/rspec/mocks/any_instance/chain.rb

Direct Known Subclasses

ExpectationChain

Instance Method Summary (collapse)

Constructor Details

- (Chain) initialize(*args, &block)

A new instance of Chain



5
6
7
8
# File 'lib/rspec/mocks/any_instance/chain.rb', line 5

def initialize(*args, &block)
  @expectation_args  = args
  @expectation_block = block
end

Instance Method Details

- (Object) and_call_original(*args, &block)

Records the and_call_original message for playback against an instance that invokes a method stubbed or mocked using any_instance.



33
# File 'lib/rspec/mocks/any_instance/chain.rb', line 33

record :and_call_original

- (Object) and_raise(*args, &block)

Records the and_raise message for playback against an instance that invokes a method stubbed or mocked using any_instance.



30
# File 'lib/rspec/mocks/any_instance/chain.rb', line 30

record :and_raise

- (Object) and_return(*args, &block)

Records the and_return message for playback against an instance that invokes a method stubbed or mocked using any_instance.



29
# File 'lib/rspec/mocks/any_instance/chain.rb', line 29

record :and_return

- (Object) and_throw(*args, &block)

Records the and_throw message for playback against an instance that invokes a method stubbed or mocked using any_instance.



31
# File 'lib/rspec/mocks/any_instance/chain.rb', line 31

record :and_throw

- (Object) and_yield(*args, &block)

Records the and_yield message for playback against an instance that invokes a method stubbed or mocked using any_instance.



32
# File 'lib/rspec/mocks/any_instance/chain.rb', line 32

record :and_yield

- (Object) any_number_of_times(*args, &block)

Records the any_number_of_times message for playback against an instance that invokes a method stubbed or mocked using any_instance.



37
# File 'lib/rspec/mocks/any_instance/chain.rb', line 37

record :any_number_of_times

- (Object) at_least(*args, &block)

Records the at_least message for playback against an instance that invokes a method stubbed or mocked using any_instance.



41
# File 'lib/rspec/mocks/any_instance/chain.rb', line 41

record :at_least

- (Object) at_most(*args, &block)

Records the at_most message for playback against an instance that invokes a method stubbed or mocked using any_instance.



42
# File 'lib/rspec/mocks/any_instance/chain.rb', line 42

record :at_most

- (Object) exactly(*args, &block)

Records the exactly message for playback against an instance that invokes a method stubbed or mocked using any_instance.



38
# File 'lib/rspec/mocks/any_instance/chain.rb', line 38

record :exactly

- (Object) never(*args, &block)

Records the never message for playback against an instance that invokes a method stubbed or mocked using any_instance.



40
# File 'lib/rspec/mocks/any_instance/chain.rb', line 40

record :never

- (Object) once(*args, &block)

Records the once message for playback against an instance that invokes a method stubbed or mocked using any_instance.



35
# File 'lib/rspec/mocks/any_instance/chain.rb', line 35

record :once

- (Object) times(*args, &block)

Records the times message for playback against an instance that invokes a method stubbed or mocked using any_instance.



39
# File 'lib/rspec/mocks/any_instance/chain.rb', line 39

record :times

- (Object) twice(*args, &block)

Records the twice message for playback against an instance that invokes a method stubbed or mocked using any_instance.



36
# File 'lib/rspec/mocks/any_instance/chain.rb', line 36

record :twice

- (Object) with(*args, &block)

Records the with message for playback against an instance that invokes a method stubbed or mocked using any_instance.



34
# File 'lib/rspec/mocks/any_instance/chain.rb', line 34

record :with