twilio-test-toolkit 3.3.0 → 3.4.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -203,6 +203,18 @@ describe TwilioTestToolkit::CallScope do
203
203
  it "should not match the action on dial if it's different than the one specified" do
204
204
  @call.has_action_on_dial?("http://example.org:3000/dont_call").should be_false
205
205
  end
206
+
207
+ it "should dial a sip peer with the correct structure" do
208
+ @call = ttt_call(test_dial_with_sip_twilio_index_path, @our_number, @their_number)
209
+ @call.within_dial do |dial|
210
+ dial.has_sip?.should be_true
211
+ dial.within_sip do |sip|
212
+ sip.has_uri?("18885551234@sip.foo.bar").should be_true
213
+ sip.has_username_on_uri?("foo").should be_true
214
+ sip.has_password_on_uri?("bar").should be_true
215
+ end
216
+ end
217
+ end
206
218
  end
207
219
 
208
220
  describe "hangup" do
@@ -350,4 +362,27 @@ describe TwilioTestToolkit::CallScope do
350
362
  end
351
363
  end
352
364
  end
365
+
366
+ describe "record" do
367
+ before(:each) do
368
+ @call = ttt_call(test_record_twilio_index_path, @our_number, @their_number)
369
+ end
370
+
371
+ it "should have the expected say record methods" do
372
+ @call.should respond_to(:has_record?)
373
+ end
374
+
375
+ it "should have the right action for record" do
376
+ @call.has_action_on_record?("http://example.org:3000/record_this_call").should be_true
377
+ end
378
+
379
+ it "should have the right maxLength for record" do
380
+ @call.has_max_length_on_record?("20").should be_true
381
+ end
382
+
383
+ it "should have the right finishOnKey for record" do
384
+ @call.has_finish_on_key_on_record?("*").should be_true
385
+ end
386
+ end
353
387
  end
388
+
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twilio-test-toolkit
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.3.0
4
+ version: 3.4.0
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2013-11-21 00:00:00.000000000 Z
12
+ date: 2014-01-14 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: capybara
@@ -164,9 +164,11 @@ files:
164
164
  - spec/dummy/app/views/twilio/test_action.xml.erb
165
165
  - spec/dummy/app/views/twilio/test_dial_with_action.xml.erb
166
166
  - spec/dummy/app/views/twilio/test_dial_with_no_action.xml.erb
167
+ - spec/dummy/app/views/twilio/test_dial_with_sip.xml
167
168
  - spec/dummy/app/views/twilio/test_gather_finish_on_asterisk.xml.erb
168
169
  - spec/dummy/app/views/twilio/test_hangup.xml.erb
169
170
  - spec/dummy/app/views/twilio/test_play.xml.erb
171
+ - spec/dummy/app/views/twilio/test_record.xml
170
172
  - spec/dummy/app/views/twilio/test_redirect.xml.erb
171
173
  - spec/dummy/app/views/twilio/test_say.xml.erb
172
174
  - spec/dummy/app/views/twilio/test_start.xml.erb
@@ -187,7 +189,9 @@ files:
187
189
  - spec/dummy/config/routes.rb
188
190
  - spec/dummy/config.ru
189
191
  - spec/dummy/db/development.sqlite3
192
+ - spec/dummy/db/schema.rb
190
193
  - spec/dummy/db/test.sqlite3
194
+ - spec/dummy/log/development.log
191
195
  - spec/dummy/log/test.log
192
196
  - spec/dummy/public/404.html
193
197
  - spec/dummy/public/422.html
@@ -220,7 +224,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
220
224
  version: '0'
221
225
  requirements: []
222
226
  rubyforge_project:
223
- rubygems_version: 1.8.24
227
+ rubygems_version: 1.8.23
224
228
  signing_key:
225
229
  specification_version: 3
226
230
  summary: Better integration tests for apps that use Twilio
@@ -235,9 +239,11 @@ test_files:
235
239
  - spec/dummy/app/views/twilio/test_action.xml.erb
236
240
  - spec/dummy/app/views/twilio/test_dial_with_action.xml.erb
237
241
  - spec/dummy/app/views/twilio/test_dial_with_no_action.xml.erb
242
+ - spec/dummy/app/views/twilio/test_dial_with_sip.xml
238
243
  - spec/dummy/app/views/twilio/test_gather_finish_on_asterisk.xml.erb
239
244
  - spec/dummy/app/views/twilio/test_hangup.xml.erb
240
245
  - spec/dummy/app/views/twilio/test_play.xml.erb
246
+ - spec/dummy/app/views/twilio/test_record.xml
241
247
  - spec/dummy/app/views/twilio/test_redirect.xml.erb
242
248
  - spec/dummy/app/views/twilio/test_say.xml.erb
243
249
  - spec/dummy/app/views/twilio/test_start.xml.erb
@@ -258,7 +264,9 @@ test_files:
258
264
  - spec/dummy/config/routes.rb
259
265
  - spec/dummy/config.ru
260
266
  - spec/dummy/db/development.sqlite3
267
+ - spec/dummy/db/schema.rb
261
268
  - spec/dummy/db/test.sqlite3
269
+ - spec/dummy/log/development.log
262
270
  - spec/dummy/log/test.log
263
271
  - spec/dummy/public/404.html
264
272
  - spec/dummy/public/422.html