Module: RSpec::Mocks::VerifyingProxyMethods Private
Do not use. This module is for internal use only.
Relationships & Source Files | |
Extension / Inclusion / Inheritance Descendants | |
Included In:
| |
Defined in: | rspec-mocks/lib/rspec/mocks/verifying_proxy.rb |
Instance Method Summary
- #add_message_expectation(method_name, opts = {}, &block) Internal use only
- #add_simple_stub(method_name, *args) Internal use only
- #add_stub(method_name, opts = {}, &implementation) Internal use only
- #ensure_implemented(method_name) Internal use only
- #ensure_publicly_implemented(method_name, _object) Internal use only
Instance Method Details
#add_message_expectation(method_name, opts = {}, &block)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/verifying_proxy.rb', line 33
def (method_name, opts={}, &block) ensure_implemented(method_name) super end
#add_simple_stub(method_name, *args)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/verifying_proxy.rb', line 28
def add_simple_stub(method_name, *args) ensure_implemented(method_name) super end
#add_stub(method_name, opts = {}, &implementation)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/verifying_proxy.rb', line 23
def add_stub(method_name, opts={}, &implementation) ensure_implemented(method_name) super end
#ensure_implemented(method_name)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/verifying_proxy.rb', line 38
def ensure_implemented(method_name) return unless method_reference[method_name].unimplemented? @error_generator.raise_unimplemented_error( @doubled_module, method_name, @object ) end
#ensure_publicly_implemented(method_name, _object)
[ GitHub ]# File 'rspec-mocks/lib/rspec/mocks/verifying_proxy.rb', line 48
def ensure_publicly_implemented(method_name, _object) ensure_implemented(method_name) visibility = method_reference[method_name].visibility return if visibility == :public @error_generator.raise_non_public_error(method_name, visibility) end