Module: RSpec::Mocks::AnyInstance::Chain::Customizations Private
Relationships & Source Files | |
Extension / Inclusion / Inheritance Descendants | |
Included In:
| |
Defined in: | rspec-mocks/lib/rspec/mocks/any_instance/chain.rb |
Overview
Provides convenience methods for recording customizations on message expectations.
Class Method Summary
- .record(method_name) Internal use only
Instance Method Summary
-
#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
. -
#and_raise(*args, &block)
Records the ‘and_raise` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#and_return(*args, &block)
Records the ‘and_return` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#and_throw(*args, &block)
Records the ‘and_throw` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#and_wrap_original(*args, &block)
Records the ‘and_wrap_original` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#and_yield(*args, &block)
Records the ‘and_yield` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#at_least(*args, &block)
Records the ‘at_least` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#at_most(*args, &block)
Records the ‘at_most` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#exactly(*args, &block)
Records the ‘exactly` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#never(*args, &block)
Records the ‘never` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#once(*args, &block)
Records the ‘once` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#thrice(*args, &block)
Records the ‘thrice` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#time(*args, &block)
Records the ‘time` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#times(*args, &block)
Records the ‘times` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#twice(*args, &block)
Records the ‘twice` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
. -
#with(*args, &block)
Records the ‘with` message for playback against an instance that invokes a method stubbed or mocked using
any_instance
.
Class Method Details
.record(method_name)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 26
def self.record(method_name) define_method(method_name) do |*args, &block| record(method_name, *args, &block) end end
Instance Method Details
#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
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 36
record :and_call_original
#and_raise(*args, &block)
Records the ‘and_raise` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 33
record :and_raise
#and_return(*args, &block)
Records the ‘and_return` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 32
record :and_return
#and_throw(*args, &block)
Records the ‘and_throw` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 34
record :and_throw
#and_wrap_original(*args, &block)
Records the ‘and_wrap_original` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 37
record :and_wrap_original
#and_yield(*args, &block)
Records the ‘and_yield` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 35
record :and_yield
#at_least(*args, &block)
Records the ‘at_least` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 46
record :at_least
#at_most(*args, &block)
Records the ‘at_most` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 47
record :at_most
#exactly(*args, &block)
Records the ‘exactly` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 42
record :exactly
#never(*args, &block)
Records the ‘never` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 45
record :never
#once(*args, &block)
Records the ‘once` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 39
record :once
#thrice(*args, &block)
Records the ‘thrice` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 41
record :thrice
#time(*args, &block)
Records the ‘time` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 44
record :time
#times(*args, &block)
Records the ‘times` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 43
record :times
#twice(*args, &block)
Records the ‘twice` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 40
record :twice
#with(*args, &block)
Records the ‘with` message for playback against an instance that invokes a method stubbed or mocked using any_instance
.
# File 'rspec-mocks/lib/rspec/mocks/any_instance/chain.rb', line 38
record :with