freeclimb 1.0.0 → 2.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (204) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile.lock +1 -1
  3. data/README.md +69 -50
  4. data/docs/AccountRequest.md +3 -5
  5. data/docs/AccountResult.md +12 -12
  6. data/docs/AccountResultAllOf.md +8 -8
  7. data/docs/AddToConference.md +35 -0
  8. data/docs/AddToConferenceAllOf.md +35 -0
  9. data/docs/ApplicationList.md +9 -9
  10. data/docs/ApplicationListAllOf.md +2 -2
  11. data/docs/ApplicationRequest.md +8 -10
  12. data/docs/ApplicationResult.md +14 -14
  13. data/docs/ApplicationResultAllOf.md +10 -10
  14. data/docs/AvailableNumber.md +7 -7
  15. data/docs/AvailableNumberList.md +9 -9
  16. data/docs/AvailableNumberListAllOf.md +2 -2
  17. data/docs/BuyIncomingNumberRequest.md +4 -6
  18. data/docs/CallList.md +9 -9
  19. data/docs/CallListAllOf.md +2 -2
  20. data/docs/CallResult.md +20 -20
  21. data/docs/CallResultAllOf.md +16 -16
  22. data/docs/ConferenceList.md +9 -9
  23. data/docs/ConferenceListAllOf.md +2 -2
  24. data/docs/ConferenceParticipantList.md +9 -9
  25. data/docs/ConferenceParticipantListAllOf.md +2 -2
  26. data/docs/ConferenceParticipantResult.md +11 -11
  27. data/docs/ConferenceParticipantResultAllOf.md +7 -7
  28. data/docs/ConferenceResult.md +15 -15
  29. data/docs/ConferenceResultAllOf.md +11 -11
  30. data/docs/CreateConference.md +27 -0
  31. data/docs/CreateConferenceAllOf.md +27 -0
  32. data/docs/CreateConferenceRequest.md +6 -8
  33. data/docs/DefaultApi.md +70 -86
  34. data/docs/Dequeue.md +16 -0
  35. data/docs/Enqueue.md +23 -0
  36. data/docs/EnqueueAllOf.md +23 -0
  37. data/docs/FilterLogsRequest.md +2 -4
  38. data/docs/GetDigits.md +33 -0
  39. data/docs/GetDigitsAllOf.md +33 -0
  40. data/docs/GetSpeech.md +41 -0
  41. data/docs/GetSpeechAllOf.md +41 -0
  42. data/docs/IncomingNumberList.md +9 -9
  43. data/docs/IncomingNumberListAllOf.md +2 -2
  44. data/docs/IncomingNumberRequest.md +3 -5
  45. data/docs/IncomingNumberResult.md +14 -14
  46. data/docs/IncomingNumberResultAllOf.md +10 -10
  47. data/docs/LogList.md +9 -9
  48. data/docs/LogListAllOf.md +2 -2
  49. data/docs/LogResult.md +8 -8
  50. data/docs/MakeCallRequest.md +11 -11
  51. data/docs/MessageRequest.md +10 -12
  52. data/docs/MessageRequestAllOf.md +6 -8
  53. data/docs/MessageResult.md +13 -13
  54. data/docs/MessageResultAllOf.md +9 -9
  55. data/docs/MessagesList.md +9 -9
  56. data/docs/MessagesListAllOf.md +2 -2
  57. data/docs/MutableResourceModel.md +5 -5
  58. data/docs/OutDial.md +35 -0
  59. data/docs/OutDialAllOf.md +35 -0
  60. data/docs/PaginationModel.md +8 -8
  61. data/docs/Pause.md +17 -0
  62. data/docs/PauseAllOf.md +17 -0
  63. data/docs/PerclCommand.md +17 -0
  64. data/docs/PerclScript.md +17 -0
  65. data/docs/Play.md +23 -0
  66. data/docs/PlayAllOf.md +23 -0
  67. data/docs/PlayEarlyMedia.md +17 -0
  68. data/docs/PlayEarlyMediaAllOf.md +17 -0
  69. data/docs/QueueList.md +9 -9
  70. data/docs/QueueListAllOf.md +2 -2
  71. data/docs/QueueMember.md +6 -6
  72. data/docs/QueueMemberList.md +9 -9
  73. data/docs/QueueMemberListAllOf.md +2 -2
  74. data/docs/QueueRequest.md +3 -5
  75. data/docs/QueueResult.md +12 -12
  76. data/docs/QueueResultAllOf.md +8 -8
  77. data/docs/RecordUtterance.md +27 -0
  78. data/docs/RecordUtteranceAllOf.md +27 -0
  79. data/docs/RecordingList.md +9 -9
  80. data/docs/RecordingListAllOf.md +2 -2
  81. data/docs/RecordingResult.md +10 -10
  82. data/docs/RecordingResultAllOf.md +6 -6
  83. data/docs/Redirect.md +17 -0
  84. data/docs/RedirectAllOf.md +17 -0
  85. data/docs/RemoveFromConference.md +17 -0
  86. data/docs/RemoveFromConferenceAllOf.md +17 -0
  87. data/docs/Say.md +25 -0
  88. data/docs/SayAllOf.md +25 -0
  89. data/docs/SendDigits.md +21 -0
  90. data/docs/SendDigitsAllOf.md +21 -0
  91. data/docs/SetListen.md +19 -0
  92. data/docs/SetListenAllOf.md +19 -0
  93. data/docs/SetTalk.md +19 -0
  94. data/docs/SetTalkAllOf.md +19 -0
  95. data/docs/Sms.md +23 -0
  96. data/docs/SmsAllOf.md +23 -0
  97. data/docs/StartRecordCall.md +16 -0
  98. data/docs/TerminateConference.md +17 -0
  99. data/docs/TerminateConferenceAllOf.md +17 -0
  100. data/docs/UpdateCallRequest.md +2 -4
  101. data/docs/UpdateConferenceParticipantRequest.md +3 -5
  102. data/docs/UpdateConferenceRequest.md +4 -6
  103. data/lib/freeclimb.rb +69 -2
  104. data/lib/freeclimb/api/default_api.rb +96 -88
  105. data/lib/freeclimb/api_client.rb +1 -1
  106. data/lib/freeclimb/models/account_request.rb +4 -14
  107. data/lib/freeclimb/models/add_to_conference.rb +320 -0
  108. data/lib/freeclimb/models/add_to_conference_all_of.rb +307 -0
  109. data/lib/freeclimb/models/application_request.rb +4 -14
  110. data/lib/freeclimb/models/buy_incoming_number_request.rb +4 -14
  111. data/lib/freeclimb/models/create_conference.rb +275 -0
  112. data/lib/freeclimb/models/create_conference_all_of.rb +262 -0
  113. data/lib/freeclimb/models/create_conference_request.rb +4 -14
  114. data/lib/freeclimb/models/dequeue.rb +209 -0
  115. data/lib/freeclimb/models/enqueue.rb +265 -0
  116. data/lib/freeclimb/models/enqueue_all_of.rb +252 -0
  117. data/lib/freeclimb/models/filter_logs_request.rb +4 -14
  118. data/lib/freeclimb/models/get_digits.rb +307 -0
  119. data/lib/freeclimb/models/get_digits_all_of.rb +294 -0
  120. data/lib/freeclimb/models/get_speech.rb +352 -0
  121. data/lib/freeclimb/models/get_speech_all_of.rb +339 -0
  122. data/lib/freeclimb/models/incoming_number_request.rb +4 -14
  123. data/lib/freeclimb/models/make_call_request.rb +14 -14
  124. data/lib/freeclimb/models/message_request.rb +1 -11
  125. data/lib/freeclimb/models/message_request_all_of.rb +1 -11
  126. data/lib/freeclimb/models/out_dial.rb +330 -0
  127. data/lib/freeclimb/models/out_dial_all_of.rb +317 -0
  128. data/lib/freeclimb/models/pause.rb +225 -0
  129. data/lib/freeclimb/models/{dequeue_member_request.rb → pause_all_of.rb} +16 -11
  130. data/lib/freeclimb/models/percl_command.rb +211 -0
  131. data/lib/freeclimb/models/percl_script.rb +210 -0
  132. data/lib/freeclimb/models/play.rb +255 -0
  133. data/lib/freeclimb/models/play_all_of.rb +242 -0
  134. data/lib/freeclimb/models/play_early_media.rb +225 -0
  135. data/lib/freeclimb/models/play_early_media_all_of.rb +212 -0
  136. data/lib/freeclimb/models/queue_request.rb +4 -14
  137. data/lib/freeclimb/models/record_utterance.rb +275 -0
  138. data/lib/freeclimb/models/record_utterance_all_of.rb +262 -0
  139. data/lib/freeclimb/models/redirect.rb +220 -0
  140. data/lib/freeclimb/models/redirect_all_of.rb +207 -0
  141. data/lib/freeclimb/models/remove_from_conference.rb +225 -0
  142. data/lib/freeclimb/models/remove_from_conference_all_of.rb +212 -0
  143. data/lib/freeclimb/models/say.rb +265 -0
  144. data/lib/freeclimb/models/say_all_of.rb +252 -0
  145. data/lib/freeclimb/models/send_digits.rb +245 -0
  146. data/lib/freeclimb/models/send_digits_all_of.rb +232 -0
  147. data/lib/freeclimb/models/set_listen.rb +235 -0
  148. data/lib/freeclimb/models/set_listen_all_of.rb +222 -0
  149. data/lib/freeclimb/models/set_talk.rb +235 -0
  150. data/lib/freeclimb/models/set_talk_all_of.rb +222 -0
  151. data/lib/freeclimb/models/sms.rb +265 -0
  152. data/lib/freeclimb/models/sms_all_of.rb +252 -0
  153. data/lib/freeclimb/models/start_record_call.rb +209 -0
  154. data/lib/freeclimb/models/terminate_conference.rb +225 -0
  155. data/lib/freeclimb/models/terminate_conference_all_of.rb +212 -0
  156. data/lib/freeclimb/models/update_call_request.rb +4 -14
  157. data/lib/freeclimb/models/update_conference_participant_request.rb +4 -14
  158. data/lib/freeclimb/models/update_conference_request.rb +4 -14
  159. data/lib/freeclimb/version.rb +1 -1
  160. data/spec/api/default_api_spec.rb +9 -24
  161. data/spec/models/add_to_conference_spec.rb +95 -0
  162. data/spec/models/create_conference_spec.rb +71 -0
  163. data/spec/models/{dequeue_member_request_spec.rb → dequeue_spec.rb} +8 -7
  164. data/spec/models/enqueue_spec.rb +59 -0
  165. data/spec/models/get_digits_spec.rb +83 -0
  166. data/spec/models/get_speech_spec.rb +113 -0
  167. data/spec/models/out_dial_spec.rb +89 -0
  168. data/spec/models/pause_spec.rb +41 -0
  169. data/spec/models/percl_command_spec.rb +41 -0
  170. data/spec/models/percl_script_spec.rb +41 -0
  171. data/spec/models/play_early_media_spec.rb +41 -0
  172. data/spec/models/play_spec.rb +53 -0
  173. data/spec/models/record_utterance_spec.rb +71 -0
  174. data/spec/models/redirect_spec.rb +41 -0
  175. data/spec/models/remove_from_conference_spec.rb +41 -0
  176. data/spec/models/say_spec.rb +65 -0
  177. data/spec/models/send_digits_spec.rb +47 -0
  178. data/spec/models/set_listen_spec.rb +47 -0
  179. data/spec/models/set_talk_spec.rb +47 -0
  180. data/spec/models/sms_spec.rb +59 -0
  181. data/spec/models/start_record_call_spec.rb +35 -0
  182. data/spec/models/terminate_conference_spec.rb +41 -0
  183. metadata +126 -35
  184. data/docs/DequeueMemberRequest.md +0 -17
  185. data/docs/Percl.md +0 -697
  186. data/git_push.sh +0 -58
  187. data/lib/percl/calls.rb +0 -43
  188. data/lib/percl/conference_participants.rb +0 -40
  189. data/lib/percl/conferences.rb +0 -21
  190. data/lib/percl/ivr.rb +0 -63
  191. data/lib/percl/jsonable.rb +0 -23
  192. data/lib/percl/percl.rb +0 -29
  193. data/lib/percl/queue_members.rb +0 -15
  194. data/lib/percl/recordings.rb +0 -15
  195. data/lib/percl/sms.rb +0 -11
  196. data/spec/percl/calls_spec.rb +0 -111
  197. data/spec/percl/conference_participant_spec.rb +0 -96
  198. data/spec/percl/conference_spec.rb +0 -46
  199. data/spec/percl/ivr_spec.rb +0 -155
  200. data/spec/percl/jsonable_spec.rb +0 -28
  201. data/spec/percl/percl_spec.rb +0 -31
  202. data/spec/percl/queue_members_spec.rb +0 -35
  203. data/spec/percl/recordings_spec.rb +0 -32
  204. data/spec/percl/sms_spec.rb +0 -29
@@ -1,58 +0,0 @@
1
- #!/bin/sh
2
- # ref: https://help.github.com/articles/adding-an-existing-project-to-github-using-the-command-line/
3
- #
4
- # Usage example: /bin/sh ./git_push.sh wing328 openapi-pestore-perl "minor update" "gitlab.com"
5
-
6
- git_user_id=$1
7
- git_repo_id=$2
8
- release_note=$3
9
- git_host=$4
10
-
11
- if [ "$git_host" = "" ]; then
12
- git_host="github.com"
13
- echo "[INFO] No command line input provided. Set \$git_host to $git_host"
14
- fi
15
-
16
- if [ "$git_user_id" = "" ]; then
17
- git_user_id="GIT_USER_ID"
18
- echo "[INFO] No command line input provided. Set \$git_user_id to $git_user_id"
19
- fi
20
-
21
- if [ "$git_repo_id" = "" ]; then
22
- git_repo_id="GIT_REPO_ID"
23
- echo "[INFO] No command line input provided. Set \$git_repo_id to $git_repo_id"
24
- fi
25
-
26
- if [ "$release_note" = "" ]; then
27
- release_note="Minor update"
28
- echo "[INFO] No command line input provided. Set \$release_note to $release_note"
29
- fi
30
-
31
- # Initialize the local directory as a Git repository
32
- git init
33
-
34
- # Adds the files in the local repository and stages them for commit.
35
- git add .
36
-
37
- # Commits the tracked changes and prepares them to be pushed to a remote repository.
38
- git commit -m "$release_note"
39
-
40
- # Sets the new remote
41
- git_remote=`git remote`
42
- if [ "$git_remote" = "" ]; then # git remote not defined
43
-
44
- if [ "$GIT_TOKEN" = "" ]; then
45
- echo "[INFO] \$GIT_TOKEN (environment variable) is not set. Using the git credential in your environment."
46
- git remote add origin https://${git_host}/${git_user_id}/${git_repo_id}.git
47
- else
48
- git remote add origin https://${git_user_id}:${GIT_TOKEN}@${git_host}/${git_user_id}/${git_repo_id}.git
49
- fi
50
-
51
- fi
52
-
53
- git pull origin master
54
-
55
- # Pushes (Forces) the changes in the local repository up to the remote repository
56
- echo "Git pushing to https://${git_host}/${git_user_id}/${git_repo_id}.git"
57
- git push origin master 2>&1 | grep -v 'To https'
58
-
@@ -1,43 +0,0 @@
1
- module Percl
2
- class OutDial < JSONable
3
- attr_accessor :ifMachine
4
- attr_accessor :ifMachineUrl
5
- attr_accessor :sendDigits
6
- attr_accessor :statusCallbackUrl
7
- attr_accessor :timeout
8
- def initialize(actionUrl, callConnectUrl, callingNumber, destination)
9
- @actionUrl = actionUrl
10
- @callConnectUrl = callConnectUrl
11
- @callingNumber = callingNumber
12
- @destination = destination
13
- end
14
- end
15
-
16
- class Hangup < JSONable
17
- attr_accessor :callId
18
- attr_accessor :reason
19
- end
20
-
21
- class Pause < JSONable
22
- def initialize(length)
23
- @length = length
24
- end
25
- end
26
-
27
- class Redirect < JSONable
28
- def initialize(actionUrl)
29
- @actionUrl = actionUrl
30
- end
31
- end
32
-
33
- class SendDigits < JSONable
34
- attr_accessor :pauseMs
35
- def initialize(digits)
36
- @digits = digits
37
- end
38
- end
39
-
40
- class Reject < JSONable
41
- attr_accessor :reason
42
- end
43
- end
@@ -1,40 +0,0 @@
1
- module Percl
2
- class AddToConference < JSONable
3
- attr_accessor :startConfOnEnter
4
- attr_accessor :talk
5
- attr_accessor :listen
6
- attr_accessor :allowCallControl
7
- attr_accessor :callControlSequence
8
- attr_accessor :callControlUrl
9
- attr_accessor :leaveConferenceUrl
10
- attr_accessor :notificationUrl
11
-
12
- def initialize(confId, callId)
13
- @conferenceId = confId
14
- @callId = callId
15
- end
16
-
17
- end
18
-
19
- class RemoveFromConference < JSONable
20
- def initialize(callId)
21
- @callId = callId
22
- end
23
- end
24
-
25
- class SetListen < JSONable
26
- attr_accessor :listen
27
-
28
- def initialize(callId)
29
- @callId = callId
30
- end
31
- end
32
-
33
- class SetTalk < JSONable
34
- attr_accessor :talk
35
-
36
- def initialize(callId)
37
- @callId = callId
38
- end
39
- end
40
- end
@@ -1,21 +0,0 @@
1
- module Percl
2
- class CreateConference < JSONable
3
-
4
- attr_accessor :alias
5
- attr_accessor :playBeep
6
- attr_accessor :record
7
- attr_accessor :waitUrl
8
- attr_accessor :statusCallbackUrl
9
-
10
- def initialize(actionUrl)
11
- @actionUrl = actionUrl
12
- end
13
-
14
- end
15
-
16
- class TerminateConference < JSONable
17
- def initialize(confId)
18
- @conferenceId = confId
19
- end
20
- end
21
- end
@@ -1,63 +0,0 @@
1
- module Percl
2
- class PlayEarlyMedia < JSONable
3
- def initialize(file)
4
- @file = file
5
- end
6
- end
7
-
8
- class Say < JSONable
9
- attr_accessor :language
10
- attr_accessor :loop
11
- attr_accessor :conferenceId
12
- attr_accessor :enforcePCI
13
-
14
- def initialize(response)
15
- @text = response
16
- end
17
-
18
- end
19
-
20
- class Play < JSONable
21
- attr_accessor :loop
22
- attr_accessor :conferenceId
23
-
24
- def initialize(file)
25
- @file = file
26
- end
27
- end
28
-
29
- class GetDigits < JSONable
30
- attr_accessor :initialTimeoutMs
31
- attr_accessor :digitTimeoutMs
32
- attr_accessor :finishOnKey
33
- attr_accessor :minDigits
34
- attr_accessor :maxDigits
35
- attr_accessor :flushBuffer
36
- attr_accessor :prompts
37
- attr_accessor :enforcePCI
38
-
39
- def initialize(actionUrl)
40
- @actionUrl = actionUrl
41
- end
42
-
43
- end
44
-
45
- class GetSpeech < JSONable
46
- attr_accessor :grammarType
47
- attr_accessor :grammarRule
48
- attr_accessor :playBeep
49
- attr_accessor :prompts
50
- attr_accessor :noInputTimeoutMs
51
- attr_accessor :recognitionTimeoutMs
52
- attr_accessor :confidenceThreshold
53
- attr_accessor :speechCompleteTimeoutMs
54
- attr_accessor :speechIncompleteTimeoutMs
55
- attr_accessor :sensitivityLevel
56
- attr_accessor :enforcePCI
57
-
58
- def initialize(actionUrl, grammarFile)
59
- @actionUrl = actionUrl
60
- @grammarFile = grammarFile
61
- end
62
- end
63
- end
@@ -1,23 +0,0 @@
1
- class JSONable
2
- def as_json
3
- hash = {}
4
- self.instance_variables.each do |var|
5
- val = self.instance_variable_get var
6
- if val.instance_of? Array
7
- arr = []
8
- val.each do |prompt|
9
- arr.push prompt.as_json
10
- end
11
- hash[var.to_s.delete "@"] = arr
12
- else
13
- hash[var.to_s.delete "@"] = val
14
- end
15
- end
16
- {self.class.name.split('::').last => hash}
17
- end
18
- def from_json! string
19
- JSON.load(string).each do |var, val|
20
- self.instance_variable_set var, val
21
- end
22
- end
23
- end
@@ -1,29 +0,0 @@
1
- require_relative 'jsonable'
2
- require 'json'
3
- require_relative 'calls'
4
- require_relative 'conferences'
5
- require_relative 'conference_participants'
6
- require_relative 'ivr'
7
- require_relative 'queue_members'
8
- require_relative 'recordings'
9
- require_relative 'sms'
10
-
11
- module Percl
12
- class Script
13
- def initialize
14
- @commands = []
15
- end
16
-
17
- def add(command)
18
- @commands.push(command)
19
- end
20
-
21
- def to_json
22
- hash = []
23
- @commands.each do |command|
24
- hash.push(command.as_json)
25
- end
26
- hash.to_json
27
- end
28
- end
29
- end
@@ -1,15 +0,0 @@
1
- module Percl
2
- class Enqueue < JSONable
3
- attr_accessor :notificationUrl
4
-
5
- def initialize(queueId, waitUrl, actionUrl)
6
- @queueId = queueId
7
- @waitUrl = waitUrl
8
- @actionUrl = actionUrl
9
- end
10
-
11
- end
12
-
13
- class Dequeue < JSONable
14
- end
15
- end
@@ -1,15 +0,0 @@
1
- module Percl
2
- class RecordUtterance < JSONable
3
- attr_accessor :silenceTimeoutMs
4
- attr_accessor :finishOnKey
5
- attr_accessor :maxLengthSec
6
- attr_accessor :autoStart
7
-
8
- def initialize(actionUrl)
9
- @actionUrl = actionUrl
10
- end
11
- end
12
-
13
- class StartRecordCall < JSONable
14
- end
15
- end
@@ -1,11 +0,0 @@
1
- module Percl
2
- class Sms < JSONable
3
- attr_accessor :notificationUrl
4
-
5
- def initialize(to, from, text)
6
- @to = to
7
- @from = from
8
- @text = text
9
- end
10
- end
11
- end
@@ -1,111 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'calls' do
4
- describe 'OutDial' do
5
- describe 'initialize' do
6
- before do
7
- @instance = Percl::OutDial.new('MOCK_ACTION_URL', 'MOCK_CALL_CONNECT_URL', 'MOCK_CALLING_NUMBER', 'MOCK_DESTINATION')
8
- end
9
- it 'should set actionUrl' do
10
- actionUrl = @instance.instance_variable_get :@actionUrl
11
- expect(actionUrl).to eq('MOCK_ACTION_URL')
12
- end
13
- it 'should set callConnectUrl' do
14
- callConnectUrl = @instance.instance_variable_get :@callConnectUrl
15
- expect(callConnectUrl).to eq('MOCK_CALL_CONNECT_URL')
16
- end
17
- it 'should set callingNumber' do
18
- callingNumber = @instance.instance_variable_get :@callingNumber
19
- expect(callingNumber).to eq('MOCK_CALLING_NUMBER')
20
- end
21
- it 'should set destinationNumber' do
22
- destination = @instance.instance_variable_get :@destination
23
- expect(destination).to eq('MOCK_DESTINATION')
24
- end
25
- end
26
- describe 'instance variables' do
27
- before do
28
- @instance = Percl::OutDial.new('MOCK_ACTION_URL', 'MOCK_CALL_CONNECT_URL', 'MOCK_CALLING_NUMBER', 'MOCK_DESTINATION')
29
- end
30
- it 'should have ifMachine' do
31
- expect(@instance).to respond_to(:ifMachine)
32
- end
33
- it 'should have ifMachineUrl' do
34
- expect(@instance).to respond_to(:ifMachineUrl)
35
- end
36
- it 'should have sendDigits' do
37
- expect(@instance).to respond_to(:sendDigits)
38
- end
39
- it 'should have statusCallbackUrl' do
40
- expect(@instance).to respond_to(:statusCallbackUrl)
41
- end
42
- it 'should have timeout' do
43
- expect(@instance).to respond_to(:timeout)
44
- end
45
- end
46
- end
47
- describe 'Hangup' do
48
- describe 'instance variables' do
49
- before do
50
- @instance = Percl::Hangup.new
51
- end
52
- it 'should have callId' do
53
- expect(@instance).to respond_to(:callId)
54
- end
55
- it 'should have reason' do
56
- expect(@instance).to respond_to(:reason)
57
- end
58
- end
59
- end
60
- describe 'Pause' do
61
- describe 'initialize' do
62
- before do
63
- @instance = Percl::Pause.new(10)
64
- end
65
- it 'should set length' do
66
- actual = @instance.instance_variable_get :@length
67
- expect(actual).to eq(10)
68
- end
69
- end
70
- end
71
- describe 'Redirect' do
72
- describe 'initialize' do
73
- before do
74
- @instance = Percl::Redirect.new('MOCK_ACTION_URL')
75
- end
76
- it 'should set actionUrl' do
77
- url = @instance.instance_variable_get :@actionUrl
78
- expect(url).to eq('MOCK_ACTION_URL')
79
- end
80
- end
81
- end
82
- describe 'SendDigits' do
83
- describe 'initialize' do
84
- before do
85
- @instance = Percl::SendDigits.new('1234')
86
- end
87
- it 'should set actionUrl' do
88
- digits = @instance.instance_variable_get :@digits
89
- expect(digits).to eq('1234')
90
- end
91
- end
92
- describe 'instance variables' do
93
- before do
94
- @instance = Percl::SendDigits.new('1234')
95
- end
96
- it 'should have pauseMs' do
97
- expect(@instance).to respond_to(:pauseMs)
98
- end
99
- end
100
- end
101
- describe 'Reject' do
102
- describe 'instance variables' do
103
- before do
104
- @instance = Percl::Reject.new
105
- end
106
- it 'should have reason' do
107
- expect(@instance).to respond_to(:reason)
108
- end
109
- end
110
- end
111
- end
@@ -1,96 +0,0 @@
1
- require 'spec_helper'
2
-
3
- describe 'conference participants' do
4
- describe 'AddToConference' do
5
- describe 'initialize' do
6
- before do
7
- @instance = Percl::AddToConference.new('MOCK_CONF_ID', 'MOCK_CALL_ID')
8
- end
9
- it 'should set conferenceId' do
10
- addToConf = @instance.instance_variable_get :@conferenceId
11
- expect(addToConf).to eq('MOCK_CONF_ID')
12
- end
13
- it 'should set callId' do
14
- callId = @instance.instance_variable_get :@callId
15
- end
16
- end
17
- describe 'instance variables' do
18
- before do
19
- @instance = Percl::AddToConference.new('MOCK_CONF_ID', 'MOCK_CALL_ID')
20
- end
21
- it 'should have startConfOnEnter' do
22
- expect(@instance).to respond_to(:startConfOnEnter)
23
- end
24
- it 'should have talk' do
25
- expect(@instance).to respond_to(:talk)
26
- end
27
- it 'should have listen' do
28
- expect(@instance).to respond_to(:listen)
29
- end
30
- it 'should have allowCallControl' do
31
- expect(@instance).to respond_to(:allowCallControl)
32
- end
33
- it 'should have callControlSequence' do
34
- expect(@instance).to respond_to(:callControlSequence)
35
- end
36
- it 'should have callControlUrl' do
37
- expect(@instance).to respond_to(:callControlUrl)
38
- end
39
- it 'should have leaveConferenceUrl' do
40
- expect(@instance).to respond_to(:leaveConferenceUrl)
41
- end
42
- it 'should have notificationUrl' do
43
- expect(@instance).to respond_to(:notificationUrl)
44
- end
45
- end
46
- end
47
- describe 'RemoveFromConference' do
48
- describe 'initialize' do
49
- before do
50
- @instance = Percl::RemoveFromConference.new('MOCK_CALL_ID')
51
- end
52
- it 'should set callId' do
53
- callId = @instance.instance_variable_get :@callId
54
- expect(callId).to eq('MOCK_CALL_ID')
55
- end
56
- end
57
- end
58
- describe 'SetListen' do
59
- describe 'initialize' do
60
- before do
61
- @instance = Percl::SetListen.new('MOCK_CALL_ID')
62
- end
63
- it 'should set callId' do
64
- callId = @instance.instance_variable_get :@callId
65
- expect(callId).to eq('MOCK_CALL_ID')
66
- end
67
- end
68
- describe 'instance variables' do
69
- before do
70
- @instance = Percl::SetListen.new('MOCK_CALL_ID')
71
- end
72
- it 'should have listen' do
73
- expect(@instance).to respond_to(:listen)
74
- end
75
- end
76
- end
77
- describe 'SetTalk' do
78
- describe 'initialize' do
79
- before do
80
- @instance = Percl::SetTalk.new('MOCK_CALL_ID')
81
- end
82
- it 'should set callId' do
83
- callId = @instance.instance_variable_get :@callId
84
- expect(callId).to eq('MOCK_CALL_ID')
85
- end
86
- end
87
- describe 'instance variables' do
88
- before do
89
- @instance = Percl::SetTalk.new('MOCK_CALL_ID')
90
- end
91
- it 'should have talk' do
92
- expect(@instance).to respond_to(:talk)
93
- end
94
- end
95
- end
96
- end