spec/integration/wireless/v1/rate_plan_spec.rb in twilio-ruby-5.1.2 vs spec/integration/wireless/v1/rate_plan_spec.rb in twilio-ruby-5.2.0

- old
+ new

@@ -6,11 +6,11 @@ require 'spec_helper.rb' describe 'RatePlan' do it "can read" do - @holodeck.mock(Twilio::TwilioResponse.new(500, '')) + @holodeck.mock(Twilio::Response.new(500, '')) expect { @client.wireless.v1.rate_plans.list() }.to raise_exception(Twilio::REST::TwilioError) @@ -21,11 +21,11 @@ url: 'https://wireless.twilio.com/v1/RatePlans', ))).to eq(true) end it "receives read_empty responses" do - @holodeck.mock(Twilio::TwilioResponse.new( + @holodeck.mock(Twilio::Response.new( 200, %q[ { "meta": { "first_page_url": "https://wireless.twilio.com/v1/RatePlans?PageSize=50&Page=0", @@ -45,11 +45,11 @@ expect(actual).to_not eq(nil) end it "receives read_full responses" do - @holodeck.mock(Twilio::TwilioResponse.new( + @holodeck.mock(Twilio::Response.new( 200, %q[ { "meta": { "first_page_url": "https://wireless.twilio.com/v1/RatePlans?PageSize=50&Page=0", @@ -92,11 +92,11 @@ expect(actual).to_not eq(nil) end it "can fetch" do - @holodeck.mock(Twilio::TwilioResponse.new(500, '')) + @holodeck.mock(Twilio::Response.new(500, '')) expect { @client.wireless.v1.rate_plans("WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").fetch() }.to raise_exception(Twilio::REST::TwilioError) @@ -107,11 +107,11 @@ url: 'https://wireless.twilio.com/v1/RatePlans/WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa', ))).to eq(true) end it "receives fetch responses" do - @holodeck.mock(Twilio::TwilioResponse.new( + @holodeck.mock(Twilio::Response.new( 200, %q[ { "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "unique_name": "unique_name", @@ -141,11 +141,11 @@ expect(actual).to_not eq(nil) end it "can create" do - @holodeck.mock(Twilio::TwilioResponse.new(500, '')) + @holodeck.mock(Twilio::Response.new(500, '')) expect { @client.wireless.v1.rate_plans.create() }.to raise_exception(Twilio::REST::TwilioError) @@ -156,11 +156,11 @@ url: 'https://wireless.twilio.com/v1/RatePlans', ))).to eq(true) end it "receives create responses" do - @holodeck.mock(Twilio::TwilioResponse.new( + @holodeck.mock(Twilio::Response.new( 201, %q[ { "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "unique_name": "unique_name", @@ -190,11 +190,11 @@ expect(actual).to_not eq(nil) end it "can update" do - @holodeck.mock(Twilio::TwilioResponse.new(500, '')) + @holodeck.mock(Twilio::Response.new(500, '')) expect { @client.wireless.v1.rate_plans("WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").update() }.to raise_exception(Twilio::REST::TwilioError) @@ -205,11 +205,11 @@ url: 'https://wireless.twilio.com/v1/RatePlans/WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa', ))).to eq(true) end it "receives update responses" do - @holodeck.mock(Twilio::TwilioResponse.new( + @holodeck.mock(Twilio::Response.new( 200, %q[ { "account_sid": "ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa", "unique_name": "unique_name", @@ -239,11 +239,11 @@ expect(actual).to_not eq(nil) end it "can delete" do - @holodeck.mock(Twilio::TwilioResponse.new(500, '')) + @holodeck.mock(Twilio::Response.new(500, '')) expect { @client.wireless.v1.rate_plans("WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").delete() }.to raise_exception(Twilio::REST::TwilioError) @@ -254,10 +254,10 @@ url: 'https://wireless.twilio.com/v1/RatePlans/WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa', ))).to eq(true) end it "receives delete responses" do - @holodeck.mock(Twilio::TwilioResponse.new( + @holodeck.mock(Twilio::Response.new( 204, nil, )) actual = @client.wireless.v1.rate_plans("WPaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").delete() \ No newline at end of file