Sha256: 2961ac843e32466b36dcd6fea0814d280552e9945ab93b8d623cd8ed1801d3d0

Contents?: true

Size: 572 Bytes

Versions: 7

Compression:

Stored size: 572 Bytes

Contents

require 'spec_helper'

describe Twilio::REST::InstanceResource do
  it 'should set up an internal reference to the uri and client' do
    resource = Twilio::REST::InstanceResource.new('some/uri', 'someClient')
    resource.instance_variable_get('@path').should == 'some/uri'
    resource.instance_variable_get('@client').should == 'someClient'
  end

  it 'should set up object properties if passed' do
    params = {'SomeKey' => 'someValue'}
    resource = Twilio::REST::InstanceResource.new('uri', 'client', params)
    resource.some_key.should == 'someValue'
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
twilio-ruby-3.11.5 spec/rest/instance_resource_spec.rb
twilio-ruby-3.11.4 spec/rest/instance_resource_spec.rb
twilio-ruby-3.11.3 spec/rest/instance_resource_spec.rb
twilio-ruby-3.11.1 spec/rest/instance_resource_spec.rb
twilio-ruby-3.11.0 spec/rest/instance_resource_spec.rb
twilio-ruby-3.10.1 spec/rest/instance_resource_spec.rb
twilio-ruby-3.10.0 spec/rest/instance_resource_spec.rb