Class: RSpec::Expectations::ExpectationTarget
- Inherits:
- 
      Object
        - Object
- RSpec::Expectations::ExpectationTarget
 
- Includes:
- InstanceMethods
- Defined in:
- lib/rspec/expectations/expectation_target.rb
Overview
    Note:
    
  
ExpectationTarget is not intended to be instantiated
directly by users. Use expect instead.
Wraps the target of an expectation.
Defined Under Namespace
Modules: InstanceMethods
Instance Attribute Summary collapse
- 
  
      #target  ⇒ Object 
  
      readonly
    The target of the expectation. 
Instance Method Summary collapse
- 
  
      #initialize(value)  ⇒ ExpectationTarget 
  
    constructor
  private
    A new instance of ExpectationTarget. 
Methods included from InstanceMethods
Constructor Details
#initialize(value) ⇒ ExpectationTarget
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
Returns a new instance of ExpectationTarget.
| 31 32 33 | # File 'lib/rspec/expectations/expectation_target.rb', line 31 def initialize(value) @target = value end | 
Instance Attribute Details
#target ⇒ Object (readonly)
    Note:
    
  
this name aligns with Minitest::Expectation so that our
InstanceMethods module can be included in that class when
used in a Minitest context.
Returns the target of the expectation.
| 28 29 30 | # File 'lib/rspec/expectations/expectation_target.rb', line 28 def target @target end |