Sha256: 70e8e6a504ab0b4091f513fb32abac8a72185c89ff8216aca8f2071e506e4ab8

Contents?: true

Size: 354 Bytes

Versions: 4

Compression:

Stored size: 354 Bytes

Contents

require "spec_helper"

describe ApiClient::Base do

  it "delegates methods to scope" do
    scope = mock
    ApiClient::Base.stub(:scope).and_return(scope)
    [:fetch, :get, :put, :post, :delete, :headers, :endpoint, :options, :adapter, :params].each do |method|
      scope.should_receive(method)
      ApiClient::Base.send(method)
    end

  end

end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
api_client-0.1.3 spec/api_client/base/delegation_spec.rb
api_client-0.1.2 spec/api_client/base/delegation_spec.rb
api_client-0.1.1 spec/api_client/base/delegation_spec.rb
api_client-0.1.0 spec/api_client/base/delegation_spec.rb