class RSpec::Mocks::AndWrapOriginalImplementation
Represents an ‘and_call_original` implementation. @private
Constants
- CannotModifyFurtherError
Public Class Methods
Source
# File lib/rspec/mocks/message_expectation.rb, line 809 def initialize(method, block) @method = method @block = block end
Public Instance Methods
Source
# File lib/rspec/mocks/message_expectation.rb, line 836 def call(*args, &block) @block.call(@method, *args, &block) end
Source
# File lib/rspec/mocks/message_expectation.rb, line 816 def initial_action=(_value) raise cannot_modify_further_error end
Source
# File lib/rspec/mocks/message_expectation.rb, line 832 def inner_action true end
Source
# File lib/rspec/mocks/message_expectation.rb, line 820 def inner_action=(_value) raise cannot_modify_further_error end
Source
# File lib/rspec/mocks/message_expectation.rb, line 824 def terminal_action=(_value) raise cannot_modify_further_error end
Private Instance Methods
Source
# File lib/rspec/mocks/message_expectation.rb, line 843 def cannot_modify_further_error CannotModifyFurtherError.new "This method has already been configured " \ "to call the original implementation, and cannot be modified further." end