Class: RSpec::Mocks::Double
| Relationships & Source Files | |
| Super Chains via Extension / Inclusion / Inheritance | |
|
Instance Chain:
self,
TestDouble
|
|
| Inherits: | Object |
| Defined in: | rspec-mocks/lib/rspec/mocks/test_double.rb |
Overview
A generic test double object. double, instance_double and friends return an instance of this.
Instance Attribute Summary
TestDouble - Included
| #null_object? | Returns true if this object has received ‘as_null_object`. |
Instance Method Summary
TestDouble - Included
| #== | This allows for comparing the mock to other objects that proxy such as ActiveRecords belongs_to proxy objects. |
| #__build_mock_proxy_unless_expired, #__disallow_further_usage!, | |
| #as_null_object | Tells the object to respond to all messages. |
| #freeze | Override for default freeze implementation to prevent freezing of test doubles. |
| #initialize | Creates a new test double with a |
| #inspect, #respond_to?, #to_s, #__build_mock_proxy, #__mock_proxy, #__raise_expired_error, #assign_stubs, #initialize_copy, #method_missing | |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RSpec::Mocks::TestDouble