title: Stub geocoder with address_components in rspec
body: <p>i try to write rspec to test some code work with gem <a href="https://github.com/alexreisner/geocoder" rel="nofollow noreferrer">Geocoder</a>. With <code>location</code> is a <code>Geocoder::Result::Google</code> object, my code like : </p>
  
  <pre><code>address = location.address_components_of_type(:sublocality_level_1).first&amp;.dig('long_name')
  </code></pre>
  
  <p>and i implement stub a point like (refer <a href="https://github.com/alexreisner/geocoder#testing-apps-that-use-geocoder" rel="nofollow noreferrer">here</a> ) : 
  ```ruby</p>
  
  <pre><code>Geocoder.configure(lookup: :test)
  Geocoder::Lookup::Test.set_default_stub(
    [
      {
        'latitude'     =&gt; 35.6691084,
        'longitude'    =&gt; 139.6009546,
        'address'      =&gt; 'Address',
        'state'        =&gt; 'State',
        'city'         =&gt; 'City',
        'types'        =&gt; ['political'],
        'address_components' =&gt; [
          {
            'types' =&gt; ['sublocality_level_1'],
            'long_name' =&gt; 'level_1',
          }
        ]
      },
    ]
  )
  </code></pre>
  
  <p>i try to byebug when run rspec and check, i get : </p>
  
  <pre><code>(byebug) location.class
  Geocoder::Result::Test
  (byebug) location.address_components
  [{"types"=&gt;["sublocality_level_1"], "long_name"=&gt;"level_1"}]
  (byebug) location.respond_to?(:address_components_of_type)
  false
  </code></pre>
  
  <p><code>location.respond_to?(:address_components_of_type)</code> return false, and i can't call <code>location.address_components_of_type(:sublocality_level_1).first&amp;.dig('long_name')</code> as my expect.</p>
  
  <p><code>location</code> when run rspec is a <code>Geocoder::Result::Test</code> object</p>
  
  <p>so, can you help me to resolve this issue? many thanks</p>
  
  <hr>
  
  <p>Geocoder version: 1.4.3
  Rails version: 5.0.2</p>