punchblock 2.5.0 → 2.5.1
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 +4 -0
- data/Guardfile +1 -1
- data/lib/punchblock/translator/asterisk/call.rb +2 -2
- data/lib/punchblock/translator/dtmf_recognizer.rb +1 -0
- data/lib/punchblock/version.rb +1 -1
- data/punchblock.gemspec +1 -1
- data/spec/punchblock/translator/asterisk/call_spec.rb +6 -6
- data/spec/punchblock/translator/asterisk/component/asterisk/agi_command_spec.rb +3 -3
- data/spec/punchblock/translator/asterisk/component/input_spec.rb +4 -0
- metadata +5 -5
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 85f605669ee36883cccb2b7d33830c63b1b5de9c
|
|
4
|
+
data.tar.gz: 48f9adbd486d8605a48c8757854fb6ea2303fcaf
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 40c3712d24b3c6eaf4d78526fda48b03e71895252a0efa86c23984b4bd34c6867d8c88885f8cd9ac79b5cd25c6ba673b2e2f75a2ae326e08215911052314e3d5
|
|
7
|
+
data.tar.gz: 57c1421e0a20fc88ad2b2c41fb3eb70e6c9e658aa44c59daa1f13ba43dfa4e68c1e6a97b78e4180ced54bfed6ee11a106640f6f22bf5db11f64740fe91dca98f
|
data/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,9 @@
|
|
|
1
1
|
# [develop](https://github.com/adhearsion/punchblock)
|
|
2
2
|
|
|
3
|
+
# [v2.5.1](https://github.com/adhearsion/punchblock/compare/v2.5.0...v2.5.1) - [2014-03-31](https://rubygems.org/gems/punchblock/versions/2.5.1)
|
|
4
|
+
* Bugfix: Ensure DTMF recognisers get shut down when finishing
|
|
5
|
+
* Bugfix: Hangup reason on Asterisk was `:hangup`, should be `:hungup`. See [the Rayo spec](http://xmpp.org/extensions/xep-0327.html#def-end-reason).
|
|
6
|
+
|
|
3
7
|
# [v2.5.0](https://github.com/adhearsion/punchblock/compare/v2.4.2...v2.5.0) - [2014-03-05](https://rubygems.org/gems/punchblock/versions/2.5.0)
|
|
4
8
|
* Feature: Support language, sensitivity and minimum confidence on UniMRCP-based ASR on Asterisk
|
|
5
9
|
* Feature: Support sending messages to calls (eg SIP MESSAGE) on Asterisk
|
data/Guardfile
CHANGED
|
@@ -16,8 +16,8 @@ module Punchblock
|
|
|
16
16
|
attr_reader :id, :channel, :translator, :agi_env, :direction
|
|
17
17
|
|
|
18
18
|
HANGUP_CAUSE_TO_END_REASON = Hash.new { :error }
|
|
19
|
-
HANGUP_CAUSE_TO_END_REASON[0] = :
|
|
20
|
-
HANGUP_CAUSE_TO_END_REASON[16] = :
|
|
19
|
+
HANGUP_CAUSE_TO_END_REASON[0] = :hungup
|
|
20
|
+
HANGUP_CAUSE_TO_END_REASON[16] = :hungup
|
|
21
21
|
HANGUP_CAUSE_TO_END_REASON[17] = :busy
|
|
22
22
|
HANGUP_CAUSE_TO_END_REASON[18] = :timeout
|
|
23
23
|
HANGUP_CAUSE_TO_END_REASON[19] = :reject
|
data/lib/punchblock/version.rb
CHANGED
data/punchblock.gemspec
CHANGED
|
@@ -36,7 +36,7 @@ Gem::Specification.new do |s|
|
|
|
36
36
|
s.add_runtime_dependency %q<ruby_jid>, ["~> 1.0"]
|
|
37
37
|
|
|
38
38
|
s.add_development_dependency %q<bundler>, ["~> 1.0"]
|
|
39
|
-
s.add_development_dependency %q<rspec>, ["~> 2.
|
|
39
|
+
s.add_development_dependency %q<rspec>, ["~> 2.13"]
|
|
40
40
|
s.add_development_dependency %q<ci_reporter>, ["~> 1.6"]
|
|
41
41
|
s.add_development_dependency %q<yard>, ["~> 0.6"]
|
|
42
42
|
s.add_development_dependency %q<rake>, [">= 0"]
|
|
@@ -303,7 +303,7 @@ module Punchblock
|
|
|
303
303
|
comp_command.response(0.1).should be_a Ref
|
|
304
304
|
expected_complete_event = Punchblock::Event::Complete.new :target_call_id => subject.id, :component_id => component.id, source_uri: component.id
|
|
305
305
|
expected_complete_event.reason = Punchblock::Event::Complete::Hangup.new
|
|
306
|
-
expected_end_event = Punchblock::Event::End.new :reason => :
|
|
306
|
+
expected_end_event = Punchblock::Event::End.new :reason => :hungup, platform_code: cause, :target_call_id => subject.id
|
|
307
307
|
|
|
308
308
|
translator.should_receive(:handle_pb_event).with(expected_complete_event).once.ordered
|
|
309
309
|
translator.should_receive(:handle_pb_event).with(expected_end_event).once.ordered
|
|
@@ -338,7 +338,7 @@ module Punchblock
|
|
|
338
338
|
end
|
|
339
339
|
|
|
340
340
|
it "should use the AMI timestamp for the Rayo event" do
|
|
341
|
-
expected_end_event = Punchblock::Event::End.new reason: :
|
|
341
|
+
expected_end_event = Punchblock::Event::End.new reason: :hungup,
|
|
342
342
|
platform_code: cause,
|
|
343
343
|
target_call_id: subject.id,
|
|
344
344
|
timestamp: DateTime.new(2014, 2, 25, 22, 46, 20)
|
|
@@ -370,8 +370,8 @@ module Punchblock
|
|
|
370
370
|
let(:cause) { '0' }
|
|
371
371
|
let(:cause_txt) { 'Undefined' }
|
|
372
372
|
|
|
373
|
-
it 'should send an end (
|
|
374
|
-
expected_end_event = Punchblock::Event::End.new :reason => :
|
|
373
|
+
it 'should send an end (hungup) event to the translator' do
|
|
374
|
+
expected_end_event = Punchblock::Event::End.new :reason => :hungup,
|
|
375
375
|
platform_code: cause,
|
|
376
376
|
:target_call_id => subject.id
|
|
377
377
|
translator.should_receive(:handle_pb_event).with expected_end_event
|
|
@@ -383,8 +383,8 @@ module Punchblock
|
|
|
383
383
|
let(:cause) { '16' }
|
|
384
384
|
let(:cause_txt) { 'Normal Clearing' }
|
|
385
385
|
|
|
386
|
-
it 'should send an end (
|
|
387
|
-
expected_end_event = Punchblock::Event::End.new :reason => :
|
|
386
|
+
it 'should send an end (hungup) event to the translator' do
|
|
387
|
+
expected_end_event = Punchblock::Event::End.new :reason => :hungup,
|
|
388
388
|
platform_code: cause,
|
|
389
389
|
:target_call_id => subject.id
|
|
390
390
|
translator.should_receive(:handle_pb_event).with expected_end_event
|
|
@@ -159,8 +159,8 @@ module Punchblock
|
|
|
159
159
|
context "when the PUNCHBLOCK_END_ON_ASYNCAGI_BREAK channel var is set" do
|
|
160
160
|
let(:chan_var) { 'true' }
|
|
161
161
|
|
|
162
|
-
it 'should send an end (
|
|
163
|
-
expected_end_event = Punchblock::Event::End.new reason: :
|
|
162
|
+
it 'should send an end (hungup) event to the translator' do
|
|
163
|
+
expected_end_event = Punchblock::Event::End.new reason: :hungup,
|
|
164
164
|
platform_code: 16,
|
|
165
165
|
target_call_id: mock_call.id
|
|
166
166
|
|
|
@@ -181,7 +181,7 @@ module Punchblock
|
|
|
181
181
|
end
|
|
182
182
|
|
|
183
183
|
it "should use the AMI timestamp for the Rayo event" do
|
|
184
|
-
expected_end_event = Punchblock::Event::End.new reason: :
|
|
184
|
+
expected_end_event = Punchblock::Event::End.new reason: :hungup,
|
|
185
185
|
platform_code: 16,
|
|
186
186
|
target_call_id: mock_call.id,
|
|
187
187
|
timestamp: DateTime.new(2014, 2, 25, 22, 46, 20)
|
|
@@ -99,6 +99,10 @@ module Punchblock
|
|
|
99
99
|
subject.should_receive(:process_dtmf).never
|
|
100
100
|
send_ami_events_for_dtmf 3
|
|
101
101
|
end
|
|
102
|
+
|
|
103
|
+
it "should not leave the recognizer running" do
|
|
104
|
+
Celluloid::Actor.all.map { |a| a.class }.should_not include(Punchblock::Translator::DTMFRecognizer)
|
|
105
|
+
end
|
|
102
106
|
end
|
|
103
107
|
|
|
104
108
|
context "when the match is invalid" do
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: punchblock
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.5.
|
|
4
|
+
version: 2.5.1
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Jason Goecke
|
|
@@ -10,7 +10,7 @@ authors:
|
|
|
10
10
|
autorequire:
|
|
11
11
|
bindir: bin
|
|
12
12
|
cert_chain: []
|
|
13
|
-
date: 2014-03-
|
|
13
|
+
date: 2014-03-31 00:00:00.000000000 Z
|
|
14
14
|
dependencies:
|
|
15
15
|
- !ruby/object:Gem::Dependency
|
|
16
16
|
name: nokogiri
|
|
@@ -212,14 +212,14 @@ dependencies:
|
|
|
212
212
|
requirements:
|
|
213
213
|
- - "~>"
|
|
214
214
|
- !ruby/object:Gem::Version
|
|
215
|
-
version: '2.
|
|
215
|
+
version: '2.13'
|
|
216
216
|
type: :development
|
|
217
217
|
prerelease: false
|
|
218
218
|
version_requirements: !ruby/object:Gem::Requirement
|
|
219
219
|
requirements:
|
|
220
220
|
- - "~>"
|
|
221
221
|
- !ruby/object:Gem::Version
|
|
222
|
-
version: '2.
|
|
222
|
+
version: '2.13'
|
|
223
223
|
- !ruby/object:Gem::Dependency
|
|
224
224
|
name: ci_reporter
|
|
225
225
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -558,7 +558,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
|
558
558
|
version: 1.3.7
|
|
559
559
|
requirements: []
|
|
560
560
|
rubyforge_project: punchblock
|
|
561
|
-
rubygems_version: 2.2.
|
|
561
|
+
rubygems_version: 2.2.2
|
|
562
562
|
signing_key:
|
|
563
563
|
specification_version: 4
|
|
564
564
|
summary: Punchblock is a telephony middleware library
|