spec/integration/api/v2010/account/call/notification_spec.rb in twilio-ruby-5.0.0.rc18 vs spec/integration/api/v2010/account/call/notification_spec.rb in twilio-ruby-5.0.0.rc19
- old
+ new
@@ -1,23 +1,23 @@
##
# This code was generated by
# \ / _ _ _| _ _
# | (_)\/(_)(_|\/| |(/_ v1.0.0
-# / /
+# / /
require 'spec_helper.rb'
describe 'Notification' do
it "can fetch" do
@holodeck.mock(Twilio::TwilioResponse.new(500, ''))
-
+
expect {
@client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications("NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").fetch()
}.to raise_exception(Twilio::REST::TwilioException)
-
+
values = {}
expect(
@holodeck.has_request?(Holodeck::Request.new(
method: 'get',
url: 'https://api.twilio.com/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Calls/CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications/NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.json',
@@ -47,27 +47,27 @@
"sid": "NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa",
"uri": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications/NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.json"
}
]
))
-
+
actual = @client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications("NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").fetch()
-
+
expect(actual).to_not eq(nil)
end
it "can delete" do
@holodeck.mock(Twilio::TwilioResponse.new(500, ''))
-
+
expect {
@client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications("NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").delete()
}.to raise_exception(Twilio::REST::TwilioException)
-
+
values = {}
expect(
@holodeck.has_request?(Holodeck::Request.new(
method: 'delete',
url: 'https://api.twilio.com/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Calls/CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications/NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa.json',
@@ -77,27 +77,27 @@
it "receives delete responses" do
@holodeck.mock(Twilio::TwilioResponse.new(
204,
nil,
))
-
+
actual = @client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications("NOaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa").delete()
-
+
expect(actual).to eq(true)
end
it "can read" do
@holodeck.mock(Twilio::TwilioResponse.new(500, ''))
-
+
expect {
@client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications.list()
}.to raise_exception(Twilio::REST::TwilioException)
-
+
values = {}
expect(
@holodeck.has_request?(Holodeck::Request.new(
method: 'get',
url: 'https://api.twilio.com/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Calls/CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications.json',
@@ -139,15 +139,15 @@
"total": 1,
"uri": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Calls/CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications.json"
}
]
))
-
+
actual = @client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications.list()
-
+
expect(actual).to_not eq(nil)
end
it "receives read_empty responses" do
@holodeck.mock(Twilio::TwilioResponse.new(
@@ -167,13 +167,13 @@
"total": 1,
"uri": "/2010-04-01/Accounts/ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Calls/CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa/Notifications.json"
}
]
))
-
+
actual = @client.api.v2010.accounts("ACaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.calls("CAaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") \
.notifications.list()
-
+
expect(actual).to_not eq(nil)
end
end
\ No newline at end of file