freeclimb 5.0.0 → 5.1.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.
- checksums.yaml +4 -4
- data/CHANGELOG.md +12 -1
- data/Gemfile +2 -1
- data/Gemfile.lock +21 -15
- data/README.md +5 -4
- data/docs/MessageResult.md +7 -1
- data/docs/TFNCampaign.md +34 -0
- data/lib/freeclimb/configuration.rb +1 -2
- data/lib/freeclimb/models/dequeue.rb +2 -4
- data/lib/freeclimb/models/message_result.rb +36 -5
- data/lib/freeclimb/models/remove_from_conference.rb +2 -4
- data/lib/freeclimb/models/start_record_call.rb +2 -4
- data/lib/freeclimb/models/terminate_conference.rb +2 -4
- data/lib/freeclimb/models/tfn_campaign.rb +370 -0
- data/lib/freeclimb/models/unpark.rb +2 -4
- data/lib/freeclimb/version.rb +1 -1
- data/lib/freeclimb.rb +1 -0
- data/openapi.json +93 -38
- data/spec/api/default_api_spec.rb +39 -117
- data/spec/models/account_request_spec.rb +113 -2
- data/spec/models/account_result_spec.rb +591 -28
- data/spec/models/account_status_spec.rb +1 -0
- data/spec/models/account_type_spec.rb +1 -0
- data/spec/models/add_to_conference_notification_webhook_spec.rb +654 -5
- data/spec/models/add_to_conference_spec.rb +471 -2
- data/spec/models/add_to_queue_notification_webhook_spec.rb +465 -2
- data/spec/models/answered_by_spec.rb +1 -0
- data/spec/models/application_list_spec.rb +323 -2
- data/spec/models/application_request_spec.rb +393 -2
- data/spec/models/application_result_spec.rb +723 -14
- data/spec/models/available_number_list_spec.rb +323 -2
- data/spec/models/available_number_spec.rb +380 -21
- data/spec/models/barge_in_reason_spec.rb +1 -0
- data/spec/models/buy_incoming_number_request_spec.rb +169 -2
- data/spec/models/call_control_webhook_spec.rb +281 -2
- data/spec/models/call_direction_spec.rb +1 -0
- data/spec/models/call_ended_reason_spec.rb +1 -0
- data/spec/models/call_list_spec.rb +323 -2
- data/spec/models/call_result_spec.rb +1020 -9
- data/spec/models/call_status_spec.rb +1 -0
- data/spec/models/call_status_webhook_spec.rb +501 -2
- data/spec/models/capabilities_spec.rb +191 -2
- data/spec/models/completion_request_spec.rb +54 -2
- data/spec/models/completion_result_spec.rb +93 -2
- data/spec/models/completion_result_status_spec.rb +1 -0
- data/spec/models/conference_list_spec.rb +323 -2
- data/spec/models/conference_participant_list_spec.rb +323 -2
- data/spec/models/conference_participant_result_spec.rb +532 -7
- data/spec/models/conference_recording_status_webhook_spec.rb +654 -5
- data/spec/models/conference_result_spec.rb +768 -55
- data/spec/models/conference_status_spec.rb +1 -0
- data/spec/models/conference_status_webhook_spec.rb +654 -5
- data/spec/models/create_conference_request_spec.rb +243 -2
- data/spec/models/create_conference_spec.rb +281 -2
- data/spec/models/create_conference_webhook_spec.rb +654 -5
- data/spec/models/create_web_rtc_token_spec.rb +151 -2
- data/spec/models/dequeue_spec.rb +1 -0
- data/spec/models/dequeue_webhook_spec.rb +565 -8
- data/spec/models/enqueue_spec.rb +225 -2
- data/spec/models/filter_logs_request_spec.rb +57 -2
- data/spec/models/get_digits_reason_spec.rb +1 -0
- data/spec/models/get_digits_spec.rb +379 -2
- data/spec/models/get_digits_webhook_spec.rb +623 -12
- data/spec/models/get_speech_reason_spec.rb +1 -0
- data/spec/models/get_speech_spec.rb +556 -11
- data/spec/models/get_speech_webhook_spec.rb +870 -15
- data/spec/models/grammar_file_built_in_spec.rb +1 -0
- data/spec/models/grammar_type_spec.rb +1 -0
- data/spec/models/hangup_spec.rb +57 -2
- data/spec/models/if_machine_spec.rb +1 -0
- data/spec/models/inbound_call_webhook_spec.rb +521 -2
- data/spec/models/incoming_number_list_spec.rb +323 -2
- data/spec/models/incoming_number_request_spec.rb +169 -2
- data/spec/models/incoming_number_result_spec.rb +930 -43
- data/spec/models/language_spec.rb +1 -0
- data/spec/models/leave_conference_webhook_spec.rb +465 -2
- data/spec/models/log_level_spec.rb +1 -0
- data/spec/models/log_list_spec.rb +323 -2
- data/spec/models/log_result_spec.rb +368 -9
- data/spec/models/machine_detected_webhook_spec.rb +565 -10
- data/spec/models/machine_type_spec.rb +1 -0
- data/spec/models/make_call_request_spec.rb +529 -6
- data/spec/models/message_delivery_webhook_spec.rb +565 -6
- data/spec/models/message_direction_spec.rb +1 -0
- data/spec/models/message_request_spec.rb +469 -2
- data/spec/models/message_result_spec.rb +1364 -225
- data/spec/models/message_status_spec.rb +1 -0
- data/spec/models/message_status_webhook_spec.rb +615 -20
- data/spec/models/messages_list_spec.rb +323 -2
- data/spec/models/mutable_resource_model_spec.rb +207 -2
- data/spec/models/out_dial_api_connect_webhook_spec.rb +521 -2
- data/spec/models/out_dial_connect_webhook_spec.rb +521 -2
- data/spec/models/out_dial_spec.rb +505 -2
- data/spec/models/out_dial_start_webhook_spec.rb +599 -24
- data/spec/models/pagination_model_spec.rb +285 -2
- data/spec/models/park_spec.rb +169 -2
- data/spec/models/pause_spec.rb +39 -2
- data/spec/models/percl_command_spec.rb +54 -2
- data/spec/models/percl_script_spec.rb +39 -2
- data/spec/models/play_beep_spec.rb +1 -0
- data/spec/models/play_early_media_spec.rb +57 -2
- data/spec/models/play_spec.rb +133 -2
- data/spec/models/queue_list_spec.rb +323 -2
- data/spec/models/queue_member_list_spec.rb +323 -2
- data/spec/models/queue_member_spec.rb +245 -2
- data/spec/models/queue_request_spec.rb +95 -2
- data/spec/models/queue_result_spec.rb +564 -15
- data/spec/models/queue_result_status_spec.rb +1 -0
- data/spec/models/queue_wait_webhook_spec.rb +616 -21
- data/spec/models/record_utterance_spec.rb +303 -2
- data/spec/models/record_utterance_term_reason_spec.rb +1 -0
- data/spec/models/record_webhook_spec.rb +868 -13
- data/spec/models/recording_list_spec.rb +323 -2
- data/spec/models/recording_result_spec.rb +469 -2
- data/spec/models/redirect_spec.rb +57 -2
- data/spec/models/redirect_webhook_spec.rb +521 -2
- data/spec/models/reject_spec.rb +57 -2
- data/spec/models/remove_from_conference_spec.rb +1 -0
- data/spec/models/remove_from_queue_notification_webhook_spec.rb +546 -9
- data/spec/models/request_type_spec.rb +1 -0
- data/spec/models/say_spec.rb +189 -2
- data/spec/models/send_digits_spec.rb +133 -2
- data/spec/models/set_dtmf_pass_through_spec.rb +39 -2
- data/spec/models/set_listen_spec.rb +39 -2
- data/spec/models/set_talk_spec.rb +39 -2
- data/spec/models/sms_spec.rb +225 -2
- data/spec/models/sms_ten_dlc_brand_alt_business_id_type_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_brand_entity_type_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_brand_identity_status_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_brand_relationship_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_brand_spec.rb +1969 -423
- data/spec/models/sms_ten_dlc_brand_stock_exchange_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_brands_list_result_spec.rb +323 -2
- data/spec/models/sms_ten_dlc_campaign_spec.rb +2224 -550
- data/spec/models/sms_ten_dlc_campaign_status_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_campaigns_list_result_spec.rb +323 -2
- data/spec/models/sms_ten_dlc_partner_campaign_brand_spec.rb +597 -17
- data/spec/models/sms_ten_dlc_partner_campaign_spec.rb +1537 -155
- data/spec/models/sms_ten_dlc_partner_campaign_status_spec.rb +1 -0
- data/spec/models/sms_ten_dlc_partner_campaigns_list_result_spec.rb +323 -2
- data/spec/models/sms_toll_free_campaign_registration_status_spec.rb +1 -0
- data/spec/models/sms_toll_free_campaign_spec.rb +355 -2
- data/spec/models/sms_toll_free_campaigns_list_result_spec.rb +323 -2
- data/spec/models/start_record_call_spec.rb +1 -0
- data/spec/models/terminate_conference_spec.rb +1 -0
- data/spec/models/tfn_campaign_spec.rb +1089 -0
- data/spec/models/tfn_spec.rb +57 -2
- data/spec/models/transcribe_reason_spec.rb +1 -0
- data/spec/models/transcribe_term_reason_spec.rb +1 -0
- data/spec/models/transcribe_utterance_record_spec.rb +115 -2
- data/spec/models/transcribe_utterance_spec.rb +288 -21
- data/spec/models/transcribe_webhook_spec.rb +1049 -4
- data/spec/models/unpark_spec.rb +1 -0
- data/spec/models/update_call_request_spec.rb +37 -2
- data/spec/models/update_call_request_status_spec.rb +1 -0
- data/spec/models/update_conference_participant_request_spec.rb +115 -2
- data/spec/models/update_conference_request_spec.rb +129 -2
- data/spec/models/update_conference_request_status_spec.rb +1 -0
- data/spec/models/webhook_spec.rb +54 -2
- metadata +129 -125
@@ -13,6 +13,7 @@ OpenAPI Generator version: 7.9.0
|
|
13
13
|
require 'spec_helper'
|
14
14
|
require 'json'
|
15
15
|
require 'date'
|
16
|
+
include Freeclimb
|
16
17
|
|
17
18
|
# Unit tests for Freeclimb::CallResult
|
18
19
|
# Automatically generated by openapi-generator (https://openapi-generator.tech)
|
@@ -28,25 +29,34 @@ describe Freeclimb::CallResult do
|
|
28
29
|
|
29
30
|
describe 'test attribute "uri"' do
|
30
31
|
it 'should work' do
|
32
|
+
|
31
33
|
instance.uri = "TEST_STRING"
|
32
34
|
expect(instance.uri).to eq("TEST_STRING")
|
33
35
|
|
36
|
+
|
37
|
+
|
34
38
|
end
|
35
39
|
end
|
36
40
|
|
37
41
|
describe 'test attribute "date_created"' do
|
38
42
|
it 'should work' do
|
43
|
+
|
39
44
|
instance.date_created = "TEST_STRING"
|
40
45
|
expect(instance.date_created).to eq("TEST_STRING")
|
41
46
|
|
47
|
+
|
48
|
+
|
42
49
|
end
|
43
50
|
end
|
44
51
|
|
45
52
|
describe 'test attribute "date_updated"' do
|
46
53
|
it 'should work' do
|
54
|
+
|
47
55
|
instance.date_updated = "TEST_STRING"
|
48
56
|
expect(instance.date_updated).to eq("TEST_STRING")
|
49
57
|
|
58
|
+
|
59
|
+
|
50
60
|
end
|
51
61
|
end
|
52
62
|
|
@@ -57,54 +67,74 @@ describe Freeclimb::CallResult do
|
|
57
67
|
instance.revision = 1
|
58
68
|
expect(instance.revision).to eq(1)
|
59
69
|
|
70
|
+
|
71
|
+
|
60
72
|
end
|
61
73
|
end
|
62
74
|
|
63
75
|
describe 'test attribute "call_id"' do
|
64
76
|
it 'should work' do
|
77
|
+
|
65
78
|
instance.call_id = "TEST_STRING"
|
66
79
|
expect(instance.call_id).to eq("TEST_STRING")
|
67
80
|
|
81
|
+
|
82
|
+
|
68
83
|
end
|
69
84
|
end
|
70
85
|
|
71
86
|
describe 'test attribute "parent_call_id"' do
|
72
87
|
it 'should work' do
|
88
|
+
|
73
89
|
instance.parent_call_id = "TEST_STRING"
|
74
90
|
expect(instance.parent_call_id).to eq("TEST_STRING")
|
75
91
|
|
92
|
+
|
93
|
+
|
76
94
|
end
|
77
95
|
end
|
78
96
|
|
79
97
|
describe 'test attribute "account_id"' do
|
80
98
|
it 'should work' do
|
99
|
+
|
81
100
|
instance.account_id = "TEST_STRING"
|
82
101
|
expect(instance.account_id).to eq("TEST_STRING")
|
83
102
|
|
103
|
+
|
104
|
+
|
84
105
|
end
|
85
106
|
end
|
86
107
|
|
87
108
|
describe 'test attribute "from"' do
|
88
109
|
it 'should work' do
|
110
|
+
|
89
111
|
instance.from = "TEST_STRING"
|
90
112
|
expect(instance.from).to eq("TEST_STRING")
|
91
113
|
|
114
|
+
|
115
|
+
|
92
116
|
end
|
93
117
|
end
|
94
118
|
|
95
119
|
describe 'test attribute "to"' do
|
96
120
|
it 'should work' do
|
121
|
+
|
97
122
|
instance.to = "TEST_STRING"
|
98
123
|
expect(instance.to).to eq("TEST_STRING")
|
99
124
|
|
125
|
+
|
126
|
+
|
100
127
|
end
|
101
128
|
end
|
102
129
|
|
103
130
|
describe 'test attribute "phone_number_id"' do
|
104
131
|
it 'should work' do
|
132
|
+
|
105
133
|
instance.phone_number_id = "TEST_STRING"
|
106
134
|
expect(instance.phone_number_id).to eq("TEST_STRING")
|
107
135
|
|
136
|
+
|
137
|
+
|
108
138
|
end
|
109
139
|
end
|
110
140
|
|
@@ -145,25 +175,34 @@ describe Freeclimb::CallResult do
|
|
145
175
|
end
|
146
176
|
describe 'test attribute "start_time"' do
|
147
177
|
it 'should work' do
|
178
|
+
|
148
179
|
instance.start_time = "TEST_STRING"
|
149
180
|
expect(instance.start_time).to eq("TEST_STRING")
|
150
181
|
|
182
|
+
|
183
|
+
|
151
184
|
end
|
152
185
|
end
|
153
186
|
|
154
187
|
describe 'test attribute "connect_time"' do
|
155
188
|
it 'should work' do
|
189
|
+
|
156
190
|
instance.connect_time = "TEST_STRING"
|
157
191
|
expect(instance.connect_time).to eq("TEST_STRING")
|
158
192
|
|
193
|
+
|
194
|
+
|
159
195
|
end
|
160
196
|
end
|
161
197
|
|
162
198
|
describe 'test attribute "end_time"' do
|
163
199
|
it 'should work' do
|
200
|
+
|
164
201
|
instance.end_time = "TEST_STRING"
|
165
202
|
expect(instance.end_time).to eq("TEST_STRING")
|
166
203
|
|
204
|
+
|
205
|
+
|
167
206
|
end
|
168
207
|
end
|
169
208
|
|
@@ -174,6 +213,8 @@ describe Freeclimb::CallResult do
|
|
174
213
|
instance.duration = 1
|
175
214
|
expect(instance.duration).to eq(1)
|
176
215
|
|
216
|
+
|
217
|
+
|
177
218
|
end
|
178
219
|
end
|
179
220
|
|
@@ -184,6 +225,8 @@ describe Freeclimb::CallResult do
|
|
184
225
|
instance.connect_duration = 1
|
185
226
|
expect(instance.connect_duration).to eq(1)
|
186
227
|
|
228
|
+
|
229
|
+
|
187
230
|
end
|
188
231
|
end
|
189
232
|
|
@@ -219,158 +262,328 @@ describe Freeclimb::CallResult do
|
|
219
262
|
testObject = Object.new()
|
220
263
|
instance.subresource_uris = testObject
|
221
264
|
expect(instance.subresource_uris).to eq(testObject)
|
265
|
+
|
266
|
+
|
267
|
+
instance.subresource_uris = Object.new
|
268
|
+
expect(instance.subresource_uris).to be_instance_of(Object)
|
269
|
+
|
222
270
|
end
|
223
271
|
end
|
224
272
|
|
225
273
|
describe 'test attribute "application_id"' do
|
226
274
|
it 'should work' do
|
275
|
+
|
227
276
|
instance.application_id = "TEST_STRING"
|
228
277
|
expect(instance.application_id).to eq("TEST_STRING")
|
229
278
|
|
279
|
+
|
280
|
+
|
230
281
|
end
|
231
282
|
end
|
232
283
|
|
233
284
|
describe 'test method "initialize"' do
|
234
285
|
it 'properly initializes with values' do
|
235
286
|
expect { instance = Freeclimb::CallResult.new(
|
287
|
+
|
236
288
|
uri: "TS",
|
237
289
|
|
290
|
+
|
291
|
+
|
292
|
+
|
238
293
|
date_created: "TS",
|
239
294
|
|
295
|
+
|
296
|
+
|
297
|
+
|
240
298
|
date_updated: "TS",
|
241
299
|
|
300
|
+
|
301
|
+
|
242
302
|
revision: 1,
|
243
303
|
|
304
|
+
|
305
|
+
|
306
|
+
|
244
307
|
call_id: "TS",
|
245
308
|
|
309
|
+
|
310
|
+
|
311
|
+
|
246
312
|
parent_call_id: "TS",
|
247
313
|
|
314
|
+
|
315
|
+
|
316
|
+
|
248
317
|
account_id: "TS",
|
249
318
|
|
319
|
+
|
320
|
+
|
321
|
+
|
250
322
|
from: "TS",
|
251
323
|
|
324
|
+
|
325
|
+
|
326
|
+
|
252
327
|
to: "TS",
|
253
328
|
|
329
|
+
|
330
|
+
|
331
|
+
|
254
332
|
phone_number_id: "TS",
|
255
333
|
|
256
334
|
|
335
|
+
|
336
|
+
|
257
337
|
call_status: Freeclimb::CallStatus::QUEUED,
|
258
338
|
|
339
|
+
|
340
|
+
|
341
|
+
|
259
342
|
start_time: "TS",
|
260
343
|
|
344
|
+
|
345
|
+
|
346
|
+
|
261
347
|
connect_time: "TS",
|
262
348
|
|
349
|
+
|
350
|
+
|
351
|
+
|
263
352
|
end_time: "TS",
|
264
353
|
|
354
|
+
|
355
|
+
|
265
356
|
duration: 1,
|
266
357
|
|
358
|
+
|
359
|
+
|
267
360
|
connect_duration: 1,
|
268
361
|
|
269
362
|
|
363
|
+
|
364
|
+
|
270
365
|
direction: Freeclimb::CallDirection::INBOUND,
|
271
366
|
|
272
367
|
|
368
|
+
|
369
|
+
|
273
370
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
274
371
|
|
372
|
+
|
373
|
+
|
374
|
+
|
375
|
+
|
376
|
+
|
275
377
|
subresource_uris: Object.new(),
|
276
378
|
|
379
|
+
|
277
380
|
application_id: "TS",
|
278
381
|
|
382
|
+
|
383
|
+
|
279
384
|
)}.not_to raise_error()
|
280
385
|
end
|
281
386
|
it 'fails to initialize with input argument that is not a hash in Freeclimb::CallResult' do
|
282
387
|
expect { instance = Freeclimb::CallResult.new(
|
388
|
+
|
283
389
|
uri: "TS",
|
284
390
|
|
391
|
+
|
392
|
+
|
393
|
+
|
285
394
|
date_created: "TS",
|
286
395
|
|
396
|
+
|
397
|
+
|
398
|
+
|
287
399
|
date_updated: "TS",
|
288
400
|
|
401
|
+
|
402
|
+
|
289
403
|
revision: 1,
|
290
404
|
|
405
|
+
|
406
|
+
|
407
|
+
|
291
408
|
call_id: "TS",
|
292
409
|
|
410
|
+
|
411
|
+
|
412
|
+
|
293
413
|
parent_call_id: "TS",
|
294
414
|
|
415
|
+
|
416
|
+
|
417
|
+
|
295
418
|
account_id: "TS",
|
296
419
|
|
420
|
+
|
421
|
+
|
422
|
+
|
297
423
|
from: "TS",
|
298
424
|
|
425
|
+
|
426
|
+
|
427
|
+
|
299
428
|
to: "TS",
|
300
429
|
|
430
|
+
|
431
|
+
|
432
|
+
|
301
433
|
phone_number_id: "TS",
|
302
434
|
|
303
435
|
|
436
|
+
|
437
|
+
|
304
438
|
call_status: Freeclimb::CallStatus::QUEUED,
|
305
439
|
|
440
|
+
|
441
|
+
|
442
|
+
|
306
443
|
start_time: "TS",
|
307
444
|
|
445
|
+
|
446
|
+
|
447
|
+
|
308
448
|
connect_time: "TS",
|
309
449
|
|
450
|
+
|
451
|
+
|
452
|
+
|
310
453
|
end_time: "TS",
|
311
454
|
|
455
|
+
|
456
|
+
|
312
457
|
duration: 1,
|
313
458
|
|
459
|
+
|
460
|
+
|
314
461
|
connect_duration: 1,
|
315
462
|
|
316
463
|
|
464
|
+
|
465
|
+
|
317
466
|
direction: Freeclimb::CallDirection::INBOUND,
|
318
467
|
|
319
468
|
|
469
|
+
|
470
|
+
|
320
471
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
321
472
|
|
322
|
-
|
473
|
+
|
474
|
+
|
475
|
+
|
476
|
+
|
477
|
+
|
478
|
+
subresource_uris: Object.new,
|
479
|
+
|
323
480
|
|
324
481
|
application_id: "TS",
|
325
482
|
|
483
|
+
|
484
|
+
|
326
485
|
invalid_attribute: true
|
327
486
|
)}.to raise_error(ArgumentError)
|
328
487
|
end
|
329
488
|
it 'fails to initialize with invalid attribute' do
|
330
489
|
expect { instance = Freeclimb::CallResult.new(
|
490
|
+
|
331
491
|
uri: "TS",
|
332
492
|
|
493
|
+
|
494
|
+
|
495
|
+
|
333
496
|
date_created: "TS",
|
334
497
|
|
498
|
+
|
499
|
+
|
500
|
+
|
335
501
|
date_updated: "TS",
|
336
502
|
|
503
|
+
|
504
|
+
|
337
505
|
revision: 1,
|
338
506
|
|
507
|
+
|
508
|
+
|
509
|
+
|
339
510
|
call_id: "TS",
|
340
511
|
|
512
|
+
|
513
|
+
|
514
|
+
|
341
515
|
parent_call_id: "TS",
|
342
516
|
|
517
|
+
|
518
|
+
|
519
|
+
|
343
520
|
account_id: "TS",
|
344
521
|
|
522
|
+
|
523
|
+
|
524
|
+
|
345
525
|
from: "TS",
|
346
526
|
|
527
|
+
|
528
|
+
|
529
|
+
|
347
530
|
to: "TS",
|
348
531
|
|
532
|
+
|
533
|
+
|
534
|
+
|
349
535
|
phone_number_id: "TS",
|
350
536
|
|
351
537
|
|
538
|
+
|
539
|
+
|
352
540
|
call_status: Freeclimb::CallStatus::QUEUED,
|
353
541
|
|
542
|
+
|
543
|
+
|
544
|
+
|
354
545
|
start_time: "TS",
|
355
546
|
|
547
|
+
|
548
|
+
|
549
|
+
|
356
550
|
connect_time: "TS",
|
357
551
|
|
552
|
+
|
553
|
+
|
554
|
+
|
358
555
|
end_time: "TS",
|
359
556
|
|
557
|
+
|
558
|
+
|
360
559
|
duration: 1,
|
361
560
|
|
561
|
+
|
562
|
+
|
362
563
|
connect_duration: 1,
|
363
564
|
|
364
565
|
|
566
|
+
|
567
|
+
|
365
568
|
direction: Freeclimb::CallDirection::INBOUND,
|
366
569
|
|
367
570
|
|
571
|
+
|
572
|
+
|
368
573
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
369
574
|
|
370
|
-
|
575
|
+
|
576
|
+
|
577
|
+
|
578
|
+
|
579
|
+
|
580
|
+
subresource_uris: Object.new,
|
581
|
+
|
371
582
|
|
372
583
|
application_id: "TS",
|
373
584
|
|
585
|
+
|
586
|
+
|
374
587
|
invalid_attribute: true
|
375
588
|
)}.to raise_error(ArgumentError)
|
376
589
|
end
|
@@ -379,49 +592,103 @@ describe Freeclimb::CallResult do
|
|
379
592
|
describe 'test method "valid"' do
|
380
593
|
it 'checks if properties are valid' do
|
381
594
|
instance = Freeclimb::CallResult.new(
|
595
|
+
|
382
596
|
uri: "TS",
|
383
597
|
|
598
|
+
|
599
|
+
|
600
|
+
|
384
601
|
date_created: "TS",
|
385
602
|
|
603
|
+
|
604
|
+
|
605
|
+
|
386
606
|
date_updated: "TS",
|
387
607
|
|
608
|
+
|
609
|
+
|
388
610
|
revision: 1,
|
389
611
|
|
612
|
+
|
613
|
+
|
614
|
+
|
390
615
|
call_id: "TS",
|
391
616
|
|
617
|
+
|
618
|
+
|
619
|
+
|
392
620
|
parent_call_id: "TS",
|
393
621
|
|
622
|
+
|
623
|
+
|
624
|
+
|
394
625
|
account_id: "TS",
|
395
626
|
|
627
|
+
|
628
|
+
|
629
|
+
|
396
630
|
from: "TS",
|
397
631
|
|
632
|
+
|
633
|
+
|
634
|
+
|
398
635
|
to: "TS",
|
399
636
|
|
637
|
+
|
638
|
+
|
639
|
+
|
400
640
|
phone_number_id: "TS",
|
401
641
|
|
402
642
|
|
643
|
+
|
644
|
+
|
403
645
|
call_status: Freeclimb::CallStatus::QUEUED,
|
404
646
|
|
647
|
+
|
648
|
+
|
649
|
+
|
405
650
|
start_time: "TS",
|
406
651
|
|
652
|
+
|
653
|
+
|
654
|
+
|
407
655
|
connect_time: "TS",
|
408
656
|
|
657
|
+
|
658
|
+
|
659
|
+
|
409
660
|
end_time: "TS",
|
410
661
|
|
662
|
+
|
663
|
+
|
411
664
|
duration: 1,
|
412
665
|
|
666
|
+
|
667
|
+
|
413
668
|
connect_duration: 1,
|
414
669
|
|
415
670
|
|
671
|
+
|
672
|
+
|
416
673
|
direction: Freeclimb::CallDirection::INBOUND,
|
417
674
|
|
418
675
|
|
676
|
+
|
677
|
+
|
419
678
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
420
679
|
|
680
|
+
|
681
|
+
|
682
|
+
|
683
|
+
|
684
|
+
|
421
685
|
subresource_uris: Object.new(),
|
422
686
|
|
687
|
+
|
423
688
|
application_id: "TS",
|
424
689
|
|
690
|
+
|
691
|
+
|
425
692
|
)
|
426
693
|
expect(instance.valid?).to eq(true)
|
427
694
|
end
|
@@ -438,190 +705,428 @@ describe Freeclimb::CallResult do
|
|
438
705
|
|
439
706
|
describe 'test method "eql?"' do
|
440
707
|
it 'checks if objects are equal' do
|
441
|
-
|
708
|
+
|
709
|
+
|
710
|
+
|
711
|
+
|
712
|
+
|
713
|
+
|
714
|
+
|
715
|
+
|
716
|
+
|
717
|
+
|
718
|
+
|
719
|
+
|
720
|
+
|
721
|
+
|
722
|
+
|
723
|
+
|
724
|
+
|
725
|
+
|
726
|
+
|
727
|
+
obj_Object = Object.new()
|
728
|
+
|
729
|
+
|
442
730
|
instance_1 = Freeclimb::CallResult.new(
|
731
|
+
|
443
732
|
uri: "TS",
|
444
733
|
|
734
|
+
|
735
|
+
|
736
|
+
|
445
737
|
date_created: "TS",
|
446
738
|
|
739
|
+
|
740
|
+
|
741
|
+
|
447
742
|
date_updated: "TS",
|
448
743
|
|
744
|
+
|
745
|
+
|
449
746
|
revision: 1,
|
450
747
|
|
748
|
+
|
749
|
+
|
750
|
+
|
451
751
|
call_id: "TS",
|
452
752
|
|
753
|
+
|
754
|
+
|
755
|
+
|
453
756
|
parent_call_id: "TS",
|
454
757
|
|
758
|
+
|
759
|
+
|
760
|
+
|
455
761
|
account_id: "TS",
|
456
762
|
|
763
|
+
|
764
|
+
|
765
|
+
|
457
766
|
from: "TS",
|
458
767
|
|
768
|
+
|
769
|
+
|
770
|
+
|
459
771
|
to: "TS",
|
460
772
|
|
773
|
+
|
774
|
+
|
775
|
+
|
461
776
|
phone_number_id: "TS",
|
462
777
|
|
463
778
|
|
779
|
+
|
780
|
+
|
781
|
+
|
782
|
+
|
464
783
|
call_status: Freeclimb::CallStatus::QUEUED,
|
465
784
|
|
785
|
+
|
466
786
|
start_time: "TS",
|
467
787
|
|
788
|
+
|
789
|
+
|
790
|
+
|
468
791
|
connect_time: "TS",
|
469
792
|
|
793
|
+
|
794
|
+
|
795
|
+
|
470
796
|
end_time: "TS",
|
471
797
|
|
798
|
+
|
799
|
+
|
472
800
|
duration: 1,
|
473
801
|
|
802
|
+
|
803
|
+
|
474
804
|
connect_duration: 1,
|
475
805
|
|
476
806
|
|
807
|
+
|
808
|
+
|
809
|
+
|
810
|
+
|
477
811
|
direction: Freeclimb::CallDirection::INBOUND,
|
478
812
|
|
479
813
|
|
814
|
+
|
815
|
+
|
480
816
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
481
817
|
|
482
|
-
|
818
|
+
|
819
|
+
|
820
|
+
subresource_uris: obj_Object,
|
821
|
+
|
822
|
+
|
483
823
|
|
484
824
|
application_id: "TS",
|
485
825
|
|
826
|
+
|
827
|
+
|
486
828
|
)
|
487
829
|
instance_2 = Freeclimb::CallResult.new(
|
830
|
+
|
488
831
|
uri: "TS",
|
489
832
|
|
833
|
+
|
834
|
+
|
835
|
+
|
490
836
|
date_created: "TS",
|
491
837
|
|
838
|
+
|
839
|
+
|
840
|
+
|
492
841
|
date_updated: "TS",
|
493
842
|
|
843
|
+
|
844
|
+
|
845
|
+
|
846
|
+
|
494
847
|
revision: 1,
|
495
848
|
|
849
|
+
|
496
850
|
call_id: "TS",
|
497
851
|
|
852
|
+
|
853
|
+
|
854
|
+
|
498
855
|
parent_call_id: "TS",
|
499
856
|
|
857
|
+
|
858
|
+
|
859
|
+
|
500
860
|
account_id: "TS",
|
501
861
|
|
862
|
+
|
863
|
+
|
864
|
+
|
502
865
|
from: "TS",
|
503
866
|
|
867
|
+
|
868
|
+
|
869
|
+
|
504
870
|
to: "TS",
|
505
871
|
|
872
|
+
|
873
|
+
|
874
|
+
|
506
875
|
phone_number_id: "TS",
|
507
876
|
|
508
877
|
|
878
|
+
|
879
|
+
|
880
|
+
|
881
|
+
|
509
882
|
call_status: Freeclimb::CallStatus::QUEUED,
|
510
883
|
|
884
|
+
|
511
885
|
start_time: "TS",
|
512
886
|
|
887
|
+
|
888
|
+
|
889
|
+
|
513
890
|
connect_time: "TS",
|
514
891
|
|
892
|
+
|
893
|
+
|
894
|
+
|
515
895
|
end_time: "TS",
|
516
896
|
|
897
|
+
|
898
|
+
|
899
|
+
|
900
|
+
|
517
901
|
duration: 1,
|
518
902
|
|
903
|
+
|
904
|
+
|
519
905
|
connect_duration: 1,
|
520
906
|
|
521
907
|
|
908
|
+
|
909
|
+
|
522
910
|
direction: Freeclimb::CallDirection::INBOUND,
|
523
911
|
|
524
912
|
|
913
|
+
|
914
|
+
|
525
915
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
526
916
|
|
527
|
-
|
917
|
+
|
918
|
+
|
919
|
+
subresource_uris: obj_Object,
|
920
|
+
|
921
|
+
|
528
922
|
|
529
923
|
application_id: "TS",
|
530
924
|
|
925
|
+
|
926
|
+
|
531
927
|
)
|
532
928
|
expect(instance_1.eql?(instance_2)).to eq(true)
|
533
929
|
end
|
534
930
|
|
535
931
|
it 'checks if objects are not equal' do
|
536
932
|
instance_1 = Freeclimb::CallResult.new(
|
933
|
+
|
537
934
|
uri: "TS",
|
538
935
|
|
936
|
+
|
937
|
+
|
938
|
+
|
539
939
|
date_created: "TS",
|
540
940
|
|
941
|
+
|
942
|
+
|
943
|
+
|
541
944
|
date_updated: "TS",
|
542
945
|
|
946
|
+
|
947
|
+
|
543
948
|
revision: 2,
|
544
949
|
|
950
|
+
|
951
|
+
|
952
|
+
|
545
953
|
call_id: "TS",
|
546
954
|
|
955
|
+
|
956
|
+
|
957
|
+
|
547
958
|
parent_call_id: "TS",
|
548
959
|
|
960
|
+
|
961
|
+
|
962
|
+
|
549
963
|
account_id: "TS",
|
550
964
|
|
965
|
+
|
966
|
+
|
967
|
+
|
551
968
|
from: "TS",
|
552
969
|
|
970
|
+
|
971
|
+
|
972
|
+
|
553
973
|
to: "TS",
|
554
974
|
|
975
|
+
|
976
|
+
|
977
|
+
|
555
978
|
phone_number_id: "TS",
|
556
979
|
|
557
980
|
|
981
|
+
|
982
|
+
|
983
|
+
|
984
|
+
|
558
985
|
call_status: Freeclimb::CallStatus::QUEUED,
|
559
986
|
|
987
|
+
|
560
988
|
start_time: "TS",
|
561
989
|
|
990
|
+
|
991
|
+
|
992
|
+
|
562
993
|
connect_time: "TS",
|
563
994
|
|
995
|
+
|
996
|
+
|
997
|
+
|
564
998
|
end_time: "TS",
|
565
999
|
|
1000
|
+
|
1001
|
+
|
566
1002
|
duration: 2,
|
567
1003
|
|
1004
|
+
|
1005
|
+
|
568
1006
|
connect_duration: 2,
|
569
1007
|
|
570
1008
|
|
1009
|
+
|
1010
|
+
|
1011
|
+
|
1012
|
+
|
571
1013
|
direction: Freeclimb::CallDirection::INBOUND,
|
572
1014
|
|
573
1015
|
|
1016
|
+
|
1017
|
+
|
574
1018
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
575
1019
|
|
1020
|
+
|
1021
|
+
|
1022
|
+
subresource_uris: Object.new(),
|
1023
|
+
|
576
1024
|
subresource_uris: Object.new(),
|
577
1025
|
|
1026
|
+
|
578
1027
|
application_id: "TS",
|
579
1028
|
|
1029
|
+
|
1030
|
+
|
580
1031
|
)
|
581
1032
|
instance_2 = Freeclimb::CallResult.new(
|
1033
|
+
|
582
1034
|
uri: "ST",
|
583
1035
|
|
1036
|
+
|
1037
|
+
|
1038
|
+
|
584
1039
|
date_created: "ST",
|
585
1040
|
|
1041
|
+
|
1042
|
+
|
1043
|
+
|
586
1044
|
date_updated: "ST",
|
587
1045
|
|
1046
|
+
|
1047
|
+
|
588
1048
|
revision: 1,
|
589
1049
|
|
1050
|
+
|
1051
|
+
|
1052
|
+
|
590
1053
|
call_id: "ST",
|
591
1054
|
|
1055
|
+
|
1056
|
+
|
1057
|
+
|
592
1058
|
parent_call_id: "ST",
|
593
1059
|
|
1060
|
+
|
1061
|
+
|
1062
|
+
|
594
1063
|
account_id: "ST",
|
595
1064
|
|
1065
|
+
|
1066
|
+
|
1067
|
+
|
596
1068
|
from: "ST",
|
597
1069
|
|
1070
|
+
|
1071
|
+
|
1072
|
+
|
598
1073
|
to: "ST",
|
599
1074
|
|
1075
|
+
|
1076
|
+
|
1077
|
+
|
600
1078
|
phone_number_id: "ST",
|
601
1079
|
|
602
1080
|
|
1081
|
+
|
1082
|
+
|
1083
|
+
|
1084
|
+
|
603
1085
|
call_status: nil,
|
604
1086
|
|
1087
|
+
|
605
1088
|
start_time: "ST",
|
606
1089
|
|
1090
|
+
|
1091
|
+
|
1092
|
+
|
607
1093
|
connect_time: "ST",
|
608
1094
|
|
1095
|
+
|
1096
|
+
|
1097
|
+
|
609
1098
|
end_time: "ST",
|
610
1099
|
|
1100
|
+
|
1101
|
+
|
611
1102
|
duration: 1,
|
612
1103
|
|
1104
|
+
|
1105
|
+
|
613
1106
|
connect_duration: 1,
|
614
1107
|
|
615
1108
|
|
1109
|
+
|
1110
|
+
|
1111
|
+
|
1112
|
+
|
616
1113
|
direction: nil,
|
617
1114
|
|
618
1115
|
|
1116
|
+
|
1117
|
+
|
619
1118
|
answered_by: nil,
|
620
1119
|
|
621
|
-
|
1120
|
+
|
1121
|
+
|
1122
|
+
subresource_uris: Object.new(),
|
1123
|
+
|
1124
|
+
|
622
1125
|
|
623
1126
|
application_id: "ST",
|
624
1127
|
|
1128
|
+
|
1129
|
+
|
625
1130
|
)
|
626
1131
|
expect(instance_1.eql?(instance_2)).to eq(false)
|
627
1132
|
end
|
@@ -630,49 +1135,103 @@ describe Freeclimb::CallResult do
|
|
630
1135
|
describe 'test method "hash"' do
|
631
1136
|
it 'calculates hash code' do
|
632
1137
|
instance = Freeclimb::CallResult.new(
|
1138
|
+
|
633
1139
|
uri: "TS",
|
634
1140
|
|
1141
|
+
|
1142
|
+
|
1143
|
+
|
635
1144
|
date_created: "TS",
|
636
1145
|
|
1146
|
+
|
1147
|
+
|
1148
|
+
|
637
1149
|
date_updated: "TS",
|
638
1150
|
|
1151
|
+
|
1152
|
+
|
639
1153
|
revision: 1,
|
640
1154
|
|
1155
|
+
|
1156
|
+
|
1157
|
+
|
641
1158
|
call_id: "TS",
|
642
1159
|
|
1160
|
+
|
1161
|
+
|
1162
|
+
|
643
1163
|
parent_call_id: "TS",
|
644
1164
|
|
1165
|
+
|
1166
|
+
|
1167
|
+
|
645
1168
|
account_id: "TS",
|
646
1169
|
|
1170
|
+
|
1171
|
+
|
1172
|
+
|
647
1173
|
from: "TS",
|
648
1174
|
|
1175
|
+
|
1176
|
+
|
1177
|
+
|
649
1178
|
to: "TS",
|
650
1179
|
|
1180
|
+
|
1181
|
+
|
1182
|
+
|
651
1183
|
phone_number_id: "TS",
|
652
1184
|
|
653
1185
|
|
1186
|
+
|
1187
|
+
|
654
1188
|
call_status: Freeclimb::CallStatus::QUEUED,
|
655
1189
|
|
1190
|
+
|
1191
|
+
|
1192
|
+
|
656
1193
|
start_time: "TS",
|
657
1194
|
|
1195
|
+
|
1196
|
+
|
1197
|
+
|
658
1198
|
connect_time: "TS",
|
659
1199
|
|
1200
|
+
|
1201
|
+
|
1202
|
+
|
660
1203
|
end_time: "TS",
|
661
1204
|
|
1205
|
+
|
1206
|
+
|
662
1207
|
duration: 1,
|
663
1208
|
|
1209
|
+
|
1210
|
+
|
664
1211
|
connect_duration: 1,
|
665
1212
|
|
666
1213
|
|
1214
|
+
|
1215
|
+
|
667
1216
|
direction: Freeclimb::CallDirection::INBOUND,
|
668
1217
|
|
669
1218
|
|
1219
|
+
|
1220
|
+
|
670
1221
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
671
1222
|
|
1223
|
+
|
1224
|
+
|
1225
|
+
|
1226
|
+
|
1227
|
+
|
672
1228
|
subresource_uris: Object.new(),
|
673
1229
|
|
1230
|
+
|
674
1231
|
application_id: "TS",
|
675
1232
|
|
1233
|
+
|
1234
|
+
|
676
1235
|
)
|
677
1236
|
expect(instance.hash).to be_a_kind_of(Integer)
|
678
1237
|
end
|
@@ -681,94 +1240,202 @@ describe Freeclimb::CallResult do
|
|
681
1240
|
describe 'test method "build_from_hash"' do
|
682
1241
|
it 'builds equivalent model from hash code' do
|
683
1242
|
instance_1 = Freeclimb::CallResult.new(
|
1243
|
+
|
684
1244
|
uri: "TS",
|
685
1245
|
|
1246
|
+
|
1247
|
+
|
1248
|
+
|
686
1249
|
date_created: "TS",
|
687
1250
|
|
1251
|
+
|
1252
|
+
|
1253
|
+
|
688
1254
|
date_updated: "TS",
|
689
1255
|
|
1256
|
+
|
1257
|
+
|
690
1258
|
revision: 1,
|
691
1259
|
|
1260
|
+
|
1261
|
+
|
1262
|
+
|
692
1263
|
call_id: "TS",
|
693
1264
|
|
1265
|
+
|
1266
|
+
|
1267
|
+
|
694
1268
|
parent_call_id: "TS",
|
695
1269
|
|
1270
|
+
|
1271
|
+
|
1272
|
+
|
696
1273
|
account_id: "TS",
|
697
1274
|
|
1275
|
+
|
1276
|
+
|
1277
|
+
|
698
1278
|
from: "TS",
|
699
1279
|
|
1280
|
+
|
1281
|
+
|
1282
|
+
|
700
1283
|
to: "TS",
|
701
1284
|
|
1285
|
+
|
1286
|
+
|
1287
|
+
|
702
1288
|
phone_number_id: "TS",
|
703
1289
|
|
704
1290
|
|
1291
|
+
|
1292
|
+
|
705
1293
|
call_status: Freeclimb::CallStatus::QUEUED,
|
706
1294
|
|
1295
|
+
|
1296
|
+
|
1297
|
+
|
707
1298
|
start_time: "TS",
|
708
1299
|
|
1300
|
+
|
1301
|
+
|
1302
|
+
|
709
1303
|
connect_time: "TS",
|
710
1304
|
|
1305
|
+
|
1306
|
+
|
1307
|
+
|
711
1308
|
end_time: "TS",
|
712
1309
|
|
1310
|
+
|
1311
|
+
|
713
1312
|
duration: 1,
|
714
1313
|
|
1314
|
+
|
1315
|
+
|
715
1316
|
connect_duration: 1,
|
716
1317
|
|
717
1318
|
|
1319
|
+
|
1320
|
+
|
718
1321
|
direction: Freeclimb::CallDirection::INBOUND,
|
719
1322
|
|
720
1323
|
|
1324
|
+
|
1325
|
+
|
721
1326
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
722
1327
|
|
1328
|
+
|
1329
|
+
|
1330
|
+
|
1331
|
+
|
1332
|
+
|
723
1333
|
subresource_uris: Object.new(),
|
724
1334
|
|
1335
|
+
|
725
1336
|
application_id: "TS",
|
726
1337
|
|
1338
|
+
|
1339
|
+
|
727
1340
|
)
|
728
1341
|
instance_2 = Freeclimb::CallResult.new(
|
1342
|
+
|
729
1343
|
uri: "TS",
|
730
1344
|
|
1345
|
+
|
1346
|
+
|
1347
|
+
|
731
1348
|
date_created: "TS",
|
732
1349
|
|
1350
|
+
|
1351
|
+
|
1352
|
+
|
733
1353
|
date_updated: "TS",
|
734
1354
|
|
1355
|
+
|
1356
|
+
|
735
1357
|
revision: 1,
|
736
1358
|
|
1359
|
+
|
1360
|
+
|
1361
|
+
|
737
1362
|
call_id: "TS",
|
738
1363
|
|
1364
|
+
|
1365
|
+
|
1366
|
+
|
739
1367
|
parent_call_id: "TS",
|
740
1368
|
|
1369
|
+
|
1370
|
+
|
1371
|
+
|
741
1372
|
account_id: "TS",
|
742
1373
|
|
1374
|
+
|
1375
|
+
|
1376
|
+
|
743
1377
|
from: "TS",
|
744
1378
|
|
1379
|
+
|
1380
|
+
|
1381
|
+
|
745
1382
|
to: "TS",
|
746
1383
|
|
1384
|
+
|
1385
|
+
|
1386
|
+
|
747
1387
|
phone_number_id: "TS",
|
748
1388
|
|
749
1389
|
|
1390
|
+
|
1391
|
+
|
750
1392
|
call_status: Freeclimb::CallStatus::QUEUED,
|
751
1393
|
|
1394
|
+
|
1395
|
+
|
1396
|
+
|
752
1397
|
start_time: "TS",
|
753
1398
|
|
1399
|
+
|
1400
|
+
|
1401
|
+
|
754
1402
|
connect_time: "TS",
|
755
1403
|
|
1404
|
+
|
1405
|
+
|
1406
|
+
|
756
1407
|
end_time: "TS",
|
757
1408
|
|
1409
|
+
|
1410
|
+
|
758
1411
|
duration: 1,
|
759
1412
|
|
1413
|
+
|
1414
|
+
|
760
1415
|
connect_duration: 1,
|
761
1416
|
|
762
1417
|
|
1418
|
+
|
1419
|
+
|
763
1420
|
direction: Freeclimb::CallDirection::INBOUND,
|
764
1421
|
|
765
1422
|
|
1423
|
+
|
1424
|
+
|
766
1425
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
767
1426
|
|
1427
|
+
|
1428
|
+
|
1429
|
+
|
1430
|
+
|
1431
|
+
|
768
1432
|
subresource_uris: Object.new(),
|
769
1433
|
|
1434
|
+
|
770
1435
|
application_id: "TS",
|
771
1436
|
|
1437
|
+
|
1438
|
+
|
772
1439
|
)
|
773
1440
|
|
774
1441
|
expect(instance_2.build_from_hash(instance_1.hash)).to eq(instance_1.build_from_hash(instance_1.hash))
|
@@ -777,149 +1444,298 @@ describe Freeclimb::CallResult do
|
|
777
1444
|
|
778
1445
|
describe 'test method "_deserialize"' do
|
779
1446
|
instance = Freeclimb::CallResult.new(
|
1447
|
+
|
780
1448
|
uri: "TS",
|
781
1449
|
|
1450
|
+
|
1451
|
+
|
1452
|
+
|
782
1453
|
date_created: "TS",
|
783
1454
|
|
1455
|
+
|
1456
|
+
|
1457
|
+
|
784
1458
|
date_updated: "TS",
|
785
1459
|
|
1460
|
+
|
1461
|
+
|
786
1462
|
revision: 1,
|
787
1463
|
|
1464
|
+
|
1465
|
+
|
1466
|
+
|
788
1467
|
call_id: "TS",
|
789
1468
|
|
1469
|
+
|
1470
|
+
|
1471
|
+
|
790
1472
|
parent_call_id: "TS",
|
791
1473
|
|
1474
|
+
|
1475
|
+
|
1476
|
+
|
792
1477
|
account_id: "TS",
|
793
1478
|
|
1479
|
+
|
1480
|
+
|
1481
|
+
|
794
1482
|
from: "TS",
|
795
1483
|
|
1484
|
+
|
1485
|
+
|
1486
|
+
|
796
1487
|
to: "TS",
|
797
1488
|
|
1489
|
+
|
1490
|
+
|
1491
|
+
|
798
1492
|
phone_number_id: "TS",
|
799
1493
|
|
800
1494
|
|
1495
|
+
|
1496
|
+
|
801
1497
|
call_status: Freeclimb::CallStatus::QUEUED,
|
802
1498
|
|
1499
|
+
|
1500
|
+
|
1501
|
+
|
803
1502
|
start_time: "TS",
|
804
1503
|
|
1504
|
+
|
1505
|
+
|
1506
|
+
|
805
1507
|
connect_time: "TS",
|
806
1508
|
|
1509
|
+
|
1510
|
+
|
1511
|
+
|
807
1512
|
end_time: "TS",
|
808
1513
|
|
1514
|
+
|
1515
|
+
|
809
1516
|
duration: 1,
|
810
1517
|
|
1518
|
+
|
1519
|
+
|
811
1520
|
connect_duration: 1,
|
812
1521
|
|
813
1522
|
|
1523
|
+
|
1524
|
+
|
814
1525
|
direction: Freeclimb::CallDirection::INBOUND,
|
815
1526
|
|
816
1527
|
|
1528
|
+
|
1529
|
+
|
817
1530
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
818
1531
|
|
1532
|
+
|
1533
|
+
|
1534
|
+
|
1535
|
+
|
1536
|
+
|
819
1537
|
subresource_uris: Object.new(),
|
820
1538
|
|
1539
|
+
|
821
1540
|
application_id: "TS",
|
822
1541
|
|
1542
|
+
|
1543
|
+
|
823
1544
|
)
|
824
1545
|
it 'deserializes the data of uri' do
|
825
1546
|
expect(instance._deserialize("String", instance.uri)).to be_a_kind_of(String)
|
826
1547
|
end
|
1548
|
+
|
1549
|
+
|
827
1550
|
it 'deserializes the data of date_created' do
|
828
1551
|
expect(instance._deserialize("String", instance.date_created)).to be_a_kind_of(String)
|
829
1552
|
end
|
1553
|
+
|
1554
|
+
|
830
1555
|
it 'deserializes the data of date_updated' do
|
831
1556
|
expect(instance._deserialize("String", instance.date_updated)).to be_a_kind_of(String)
|
832
1557
|
end
|
1558
|
+
|
1559
|
+
|
833
1560
|
it 'deserializes the data of revision' do
|
834
1561
|
expect(instance._deserialize("Integer", instance.revision)).to be_a_kind_of(Integer)
|
835
1562
|
end
|
1563
|
+
|
1564
|
+
|
836
1565
|
it 'deserializes the data of call_id' do
|
837
1566
|
expect(instance._deserialize("String", instance.call_id)).to be_a_kind_of(String)
|
838
1567
|
end
|
1568
|
+
|
1569
|
+
|
839
1570
|
it 'deserializes the data of parent_call_id' do
|
840
1571
|
expect(instance._deserialize("String", instance.parent_call_id)).to be_a_kind_of(String)
|
841
1572
|
end
|
1573
|
+
|
1574
|
+
|
842
1575
|
it 'deserializes the data of account_id' do
|
843
1576
|
expect(instance._deserialize("String", instance.account_id)).to be_a_kind_of(String)
|
844
1577
|
end
|
1578
|
+
|
1579
|
+
|
845
1580
|
it 'deserializes the data of from' do
|
846
1581
|
expect(instance._deserialize("String", instance.from)).to be_a_kind_of(String)
|
847
1582
|
end
|
1583
|
+
|
1584
|
+
|
848
1585
|
it 'deserializes the data of to' do
|
849
1586
|
expect(instance._deserialize("String", instance.to)).to be_a_kind_of(String)
|
850
1587
|
end
|
1588
|
+
|
1589
|
+
|
851
1590
|
it 'deserializes the data of phone_number_id' do
|
852
1591
|
expect(instance._deserialize("String", instance.phone_number_id)).to be_a_kind_of(String)
|
853
1592
|
end
|
1593
|
+
|
1594
|
+
|
1595
|
+
|
1596
|
+
|
854
1597
|
it 'deserializes the data of start_time' do
|
855
1598
|
expect(instance._deserialize("String", instance.start_time)).to be_a_kind_of(String)
|
856
1599
|
end
|
1600
|
+
|
1601
|
+
|
857
1602
|
it 'deserializes the data of connect_time' do
|
858
1603
|
expect(instance._deserialize("String", instance.connect_time)).to be_a_kind_of(String)
|
859
1604
|
end
|
1605
|
+
|
1606
|
+
|
860
1607
|
it 'deserializes the data of end_time' do
|
861
1608
|
expect(instance._deserialize("String", instance.end_time)).to be_a_kind_of(String)
|
862
1609
|
end
|
1610
|
+
|
1611
|
+
|
863
1612
|
it 'deserializes the data of duration' do
|
864
1613
|
expect(instance._deserialize("Integer", instance.duration)).to be_a_kind_of(Integer)
|
865
1614
|
end
|
1615
|
+
|
1616
|
+
|
866
1617
|
it 'deserializes the data of connect_duration' do
|
867
1618
|
expect(instance._deserialize("Integer", instance.connect_duration)).to be_a_kind_of(Integer)
|
868
1619
|
end
|
1620
|
+
|
1621
|
+
|
1622
|
+
|
1623
|
+
|
1624
|
+
|
1625
|
+
|
1626
|
+
|
1627
|
+
|
869
1628
|
it 'deserializes the data of subresource_uris' do
|
870
1629
|
expect(instance._deserialize("Object", instance.subresource_uris)).to be_a_kind_of(Object)
|
871
1630
|
end
|
1631
|
+
|
872
1632
|
it 'deserializes the data of application_id' do
|
873
1633
|
expect(instance._deserialize("String", instance.application_id)).to be_a_kind_of(String)
|
874
1634
|
end
|
1635
|
+
|
1636
|
+
|
875
1637
|
end
|
876
1638
|
|
877
1639
|
describe 'test method "to_s"' do
|
878
1640
|
it 'returns the string representation of the object' do
|
879
1641
|
instance = Freeclimb::CallResult.new(
|
1642
|
+
|
880
1643
|
uri: "TS",
|
881
1644
|
|
1645
|
+
|
1646
|
+
|
1647
|
+
|
882
1648
|
date_created: "TS",
|
883
1649
|
|
1650
|
+
|
1651
|
+
|
1652
|
+
|
884
1653
|
date_updated: "TS",
|
885
1654
|
|
1655
|
+
|
1656
|
+
|
886
1657
|
revision: 1,
|
887
1658
|
|
1659
|
+
|
1660
|
+
|
1661
|
+
|
888
1662
|
call_id: "TS",
|
889
1663
|
|
1664
|
+
|
1665
|
+
|
1666
|
+
|
890
1667
|
parent_call_id: "TS",
|
891
1668
|
|
1669
|
+
|
1670
|
+
|
1671
|
+
|
892
1672
|
account_id: "TS",
|
893
1673
|
|
1674
|
+
|
1675
|
+
|
1676
|
+
|
894
1677
|
from: "TS",
|
895
1678
|
|
1679
|
+
|
1680
|
+
|
1681
|
+
|
896
1682
|
to: "TS",
|
897
1683
|
|
1684
|
+
|
1685
|
+
|
1686
|
+
|
898
1687
|
phone_number_id: "TS",
|
899
1688
|
|
900
1689
|
|
1690
|
+
|
1691
|
+
|
901
1692
|
call_status: Freeclimb::CallStatus::QUEUED,
|
902
1693
|
|
1694
|
+
|
1695
|
+
|
1696
|
+
|
903
1697
|
start_time: "TS",
|
904
1698
|
|
1699
|
+
|
1700
|
+
|
1701
|
+
|
905
1702
|
connect_time: "TS",
|
906
1703
|
|
1704
|
+
|
1705
|
+
|
1706
|
+
|
907
1707
|
end_time: "TS",
|
908
1708
|
|
1709
|
+
|
1710
|
+
|
909
1711
|
duration: 1,
|
910
1712
|
|
1713
|
+
|
1714
|
+
|
911
1715
|
connect_duration: 1,
|
912
1716
|
|
913
1717
|
|
1718
|
+
|
1719
|
+
|
914
1720
|
direction: Freeclimb::CallDirection::INBOUND,
|
915
1721
|
|
916
1722
|
|
1723
|
+
|
1724
|
+
|
917
1725
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
918
1726
|
|
919
|
-
|
1727
|
+
|
1728
|
+
|
1729
|
+
|
1730
|
+
|
1731
|
+
|
1732
|
+
subresource_uris: Object.new,
|
1733
|
+
|
920
1734
|
|
921
1735
|
application_id: "TS",
|
922
1736
|
|
1737
|
+
|
1738
|
+
|
923
1739
|
)
|
924
1740
|
expect(instance.to_s).to eq(instance.to_hash.to_s)
|
925
1741
|
end
|
@@ -928,143 +1744,326 @@ describe Freeclimb::CallResult do
|
|
928
1744
|
describe 'test method "to_hash"' do
|
929
1745
|
it 'returns the object in the form of hash' do
|
930
1746
|
instance = Freeclimb::CallResult.new(
|
1747
|
+
|
931
1748
|
uri: "TS",
|
932
1749
|
|
1750
|
+
|
1751
|
+
|
1752
|
+
|
933
1753
|
date_created: "TS",
|
934
1754
|
|
1755
|
+
|
1756
|
+
|
1757
|
+
|
935
1758
|
date_updated: "TS",
|
936
1759
|
|
1760
|
+
|
1761
|
+
|
937
1762
|
revision: 1,
|
938
1763
|
|
1764
|
+
|
1765
|
+
|
1766
|
+
|
939
1767
|
call_id: "TS",
|
940
1768
|
|
1769
|
+
|
1770
|
+
|
1771
|
+
|
941
1772
|
parent_call_id: "TS",
|
942
1773
|
|
1774
|
+
|
1775
|
+
|
1776
|
+
|
943
1777
|
account_id: "TS",
|
944
1778
|
|
1779
|
+
|
1780
|
+
|
1781
|
+
|
945
1782
|
from: "TS",
|
946
1783
|
|
1784
|
+
|
1785
|
+
|
1786
|
+
|
947
1787
|
to: "TS",
|
948
1788
|
|
1789
|
+
|
1790
|
+
|
1791
|
+
|
949
1792
|
phone_number_id: "TS",
|
950
1793
|
|
951
1794
|
|
1795
|
+
|
1796
|
+
|
952
1797
|
call_status: Freeclimb::CallStatus::QUEUED,
|
953
1798
|
|
1799
|
+
|
1800
|
+
|
1801
|
+
|
954
1802
|
start_time: "TS",
|
955
1803
|
|
1804
|
+
|
1805
|
+
|
1806
|
+
|
956
1807
|
connect_time: "TS",
|
957
1808
|
|
1809
|
+
|
1810
|
+
|
1811
|
+
|
958
1812
|
end_time: "TS",
|
959
1813
|
|
1814
|
+
|
1815
|
+
|
960
1816
|
duration: 1,
|
961
1817
|
|
1818
|
+
|
1819
|
+
|
962
1820
|
connect_duration: 1,
|
963
1821
|
|
964
1822
|
|
1823
|
+
|
1824
|
+
|
965
1825
|
direction: Freeclimb::CallDirection::INBOUND,
|
966
1826
|
|
967
1827
|
|
1828
|
+
|
1829
|
+
|
968
1830
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
969
1831
|
|
970
|
-
|
1832
|
+
|
1833
|
+
|
1834
|
+
|
1835
|
+
|
1836
|
+
|
1837
|
+
subresource_uris: Object.new,
|
1838
|
+
|
971
1839
|
|
972
1840
|
application_id: "TS",
|
973
1841
|
|
1842
|
+
|
1843
|
+
|
974
1844
|
)
|
975
1845
|
expect(instance.to_hash).to be_a_kind_of(Hash)
|
976
1846
|
end
|
977
1847
|
it 'creates equal hash for two equal objects' do
|
1848
|
+
|
1849
|
+
|
1850
|
+
|
1851
|
+
|
1852
|
+
|
1853
|
+
|
1854
|
+
|
1855
|
+
|
1856
|
+
|
1857
|
+
|
1858
|
+
|
1859
|
+
|
1860
|
+
|
1861
|
+
|
1862
|
+
|
1863
|
+
|
1864
|
+
|
1865
|
+
|
1866
|
+
|
978
1867
|
obj = Object.new()
|
1868
|
+
|
1869
|
+
|
979
1870
|
instance_1 = Freeclimb::CallResult.new(
|
1871
|
+
|
980
1872
|
uri: "TS",
|
981
1873
|
|
1874
|
+
|
1875
|
+
|
1876
|
+
|
982
1877
|
date_created: "TS",
|
983
1878
|
|
1879
|
+
|
1880
|
+
|
1881
|
+
|
984
1882
|
date_updated: "TS",
|
985
1883
|
|
1884
|
+
|
1885
|
+
|
986
1886
|
revision: 1,
|
987
1887
|
|
1888
|
+
|
1889
|
+
|
1890
|
+
|
988
1891
|
call_id: "TS",
|
989
1892
|
|
1893
|
+
|
1894
|
+
|
1895
|
+
|
990
1896
|
parent_call_id: "TS",
|
991
1897
|
|
1898
|
+
|
1899
|
+
|
1900
|
+
|
992
1901
|
account_id: "TS",
|
993
1902
|
|
1903
|
+
|
1904
|
+
|
1905
|
+
|
994
1906
|
from: "TS",
|
995
1907
|
|
1908
|
+
|
1909
|
+
|
1910
|
+
|
996
1911
|
to: "TS",
|
997
1912
|
|
1913
|
+
|
1914
|
+
|
1915
|
+
|
998
1916
|
phone_number_id: "TS",
|
999
1917
|
|
1000
1918
|
|
1919
|
+
|
1920
|
+
|
1001
1921
|
call_status: Freeclimb::CallStatus::QUEUED,
|
1002
1922
|
|
1923
|
+
|
1924
|
+
|
1925
|
+
|
1003
1926
|
start_time: "TS",
|
1004
1927
|
|
1928
|
+
|
1929
|
+
|
1930
|
+
|
1005
1931
|
connect_time: "TS",
|
1006
1932
|
|
1933
|
+
|
1934
|
+
|
1935
|
+
|
1007
1936
|
end_time: "TS",
|
1008
1937
|
|
1938
|
+
|
1939
|
+
|
1009
1940
|
duration: 1,
|
1010
1941
|
|
1942
|
+
|
1943
|
+
|
1011
1944
|
connect_duration: 1,
|
1012
1945
|
|
1013
1946
|
|
1947
|
+
|
1948
|
+
|
1014
1949
|
direction: Freeclimb::CallDirection::INBOUND,
|
1015
1950
|
|
1016
1951
|
|
1952
|
+
|
1953
|
+
|
1017
1954
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
1018
1955
|
|
1956
|
+
|
1957
|
+
|
1958
|
+
|
1959
|
+
|
1960
|
+
|
1019
1961
|
subresource_uris: obj,
|
1020
1962
|
|
1963
|
+
|
1021
1964
|
application_id: "TS",
|
1022
1965
|
|
1966
|
+
|
1967
|
+
|
1023
1968
|
)
|
1024
1969
|
instance_2 = Freeclimb::CallResult.new(
|
1970
|
+
|
1025
1971
|
uri: "TS",
|
1026
1972
|
|
1973
|
+
|
1974
|
+
|
1975
|
+
|
1027
1976
|
date_created: "TS",
|
1028
1977
|
|
1978
|
+
|
1979
|
+
|
1980
|
+
|
1029
1981
|
date_updated: "TS",
|
1030
1982
|
|
1983
|
+
|
1984
|
+
|
1031
1985
|
revision: 1,
|
1032
1986
|
|
1987
|
+
|
1988
|
+
|
1989
|
+
|
1033
1990
|
call_id: "TS",
|
1034
1991
|
|
1992
|
+
|
1993
|
+
|
1994
|
+
|
1035
1995
|
parent_call_id: "TS",
|
1036
1996
|
|
1997
|
+
|
1998
|
+
|
1999
|
+
|
1037
2000
|
account_id: "TS",
|
1038
2001
|
|
2002
|
+
|
2003
|
+
|
2004
|
+
|
1039
2005
|
from: "TS",
|
1040
2006
|
|
2007
|
+
|
2008
|
+
|
2009
|
+
|
1041
2010
|
to: "TS",
|
1042
2011
|
|
2012
|
+
|
2013
|
+
|
2014
|
+
|
1043
2015
|
phone_number_id: "TS",
|
1044
2016
|
|
1045
2017
|
|
2018
|
+
|
2019
|
+
|
1046
2020
|
call_status: Freeclimb::CallStatus::QUEUED,
|
1047
2021
|
|
2022
|
+
|
2023
|
+
|
2024
|
+
|
1048
2025
|
start_time: "TS",
|
1049
2026
|
|
2027
|
+
|
2028
|
+
|
2029
|
+
|
1050
2030
|
connect_time: "TS",
|
1051
2031
|
|
2032
|
+
|
2033
|
+
|
2034
|
+
|
1052
2035
|
end_time: "TS",
|
1053
2036
|
|
2037
|
+
|
2038
|
+
|
1054
2039
|
duration: 1,
|
1055
2040
|
|
2041
|
+
|
2042
|
+
|
1056
2043
|
connect_duration: 1,
|
1057
2044
|
|
1058
2045
|
|
2046
|
+
|
2047
|
+
|
1059
2048
|
direction: Freeclimb::CallDirection::INBOUND,
|
1060
2049
|
|
1061
2050
|
|
2051
|
+
|
2052
|
+
|
1062
2053
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
1063
2054
|
|
2055
|
+
|
2056
|
+
|
2057
|
+
|
2058
|
+
|
2059
|
+
|
1064
2060
|
subresource_uris: obj,
|
1065
2061
|
|
2062
|
+
|
1066
2063
|
application_id: "TS",
|
1067
2064
|
|
2065
|
+
|
2066
|
+
|
1068
2067
|
)
|
1069
2068
|
expect(instance_1.to_hash).to eq(instance_2.to_hash)
|
1070
2069
|
end
|
@@ -1072,33 +2071,42 @@ describe Freeclimb::CallResult do
|
|
1072
2071
|
|
1073
2072
|
describe 'test method "_to_hash"' do
|
1074
2073
|
instance = Freeclimb::CallResult.new(
|
2074
|
+
|
1075
2075
|
uri: "TS",
|
1076
2076
|
|
1077
2077
|
|
2078
|
+
|
1078
2079
|
date_created: "TS",
|
1079
2080
|
|
1080
2081
|
|
2082
|
+
|
1081
2083
|
date_updated: "TS",
|
1082
2084
|
|
1083
2085
|
|
1084
2086
|
revision: 1,
|
1085
2087
|
|
1086
2088
|
|
2089
|
+
|
1087
2090
|
call_id: "TS",
|
1088
2091
|
|
1089
2092
|
|
2093
|
+
|
1090
2094
|
parent_call_id: "TS",
|
1091
2095
|
|
1092
2096
|
|
2097
|
+
|
1093
2098
|
account_id: "TS",
|
1094
2099
|
|
1095
2100
|
|
2101
|
+
|
1096
2102
|
from: "TS",
|
1097
2103
|
|
1098
2104
|
|
2105
|
+
|
1099
2106
|
to: "TS",
|
1100
2107
|
|
1101
2108
|
|
2109
|
+
|
1102
2110
|
phone_number_id: "TS",
|
1103
2111
|
|
1104
2112
|
|
@@ -1106,12 +2114,15 @@ describe Freeclimb::CallResult do
|
|
1106
2114
|
call_status: Freeclimb::CallStatus::QUEUED,
|
1107
2115
|
|
1108
2116
|
|
2117
|
+
|
1109
2118
|
start_time: "TS",
|
1110
2119
|
|
1111
2120
|
|
2121
|
+
|
1112
2122
|
connect_time: "TS",
|
1113
2123
|
|
1114
2124
|
|
2125
|
+
|
1115
2126
|
end_time: "TS",
|
1116
2127
|
|
1117
2128
|
|
@@ -1129,9 +2140,9 @@ describe Freeclimb::CallResult do
|
|
1129
2140
|
answered_by: Freeclimb::AnsweredBy::HUMAN,
|
1130
2141
|
|
1131
2142
|
|
1132
|
-
subresource_uris: Object.new(),
|
1133
2143
|
|
1134
2144
|
|
2145
|
+
|
1135
2146
|
application_id: "TS",
|
1136
2147
|
|
1137
2148
|
)
|