Sha256: 39077e6af59cf3c031fb5c1a393b05468cd1d96e16795e42b6c58690a7467fc8

Contents?: true

Size: 714 Bytes

Versions: 23

Compression:

Stored size: 714 Bytes

Contents

require 'spec_helper'

describe ApiResource::Associations::AssociationProxy do

  before(:all) do
    TestResource.reload_resource_definition
  end

  context "Methods that collide with enumerables" do

    it "should not include enumerables" do
      test_resource = TestResource.find(1)
      # the #zip method is included in enumerable
      test_resource.belongs_to_object.zip.should_not be_blank
    end

  end

  context "#remote_path" do

    it "should provide access to its remote path when 
      instantiated through a parent" do

      test_resource = TestResource.find(1)
      test_resource.has_many_service_uri.remote_path.should eql(
        "/test_resource/1/has_many"
      )

    end

  end

end

Version data entries

23 entries across 23 versions & 1 rubygems

Version Path
api_resource-0.6.25 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.24 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.23 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.22 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.21 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.20 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.19 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.18 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.17 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.16 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.15 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.14 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.13 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.12 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.11 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.9 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.10 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.8 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.7 spec/lib/associations/association_scope_spec.rb
api_resource-0.6.6 spec/lib/associations/association_scope_spec.rb