ruby-bandwidth 2.0.4 → 2.0.5

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 3fcee5f7142eb6cfd4e73f6e5913525ffbabf384ea10a5dbef827168af2e2d17
4
- data.tar.gz: 1b56bcdeaa54fe10a9f275ed578231cdad61e00b83be828fab76a129ff67ddcb
3
+ metadata.gz: cd9f0fa3f41a6851974cb137e692313a4356dafcee42ff40a360501c166a4366
4
+ data.tar.gz: 7d60cd906ca368a17314279d11e90f9613c41a814b9688cb5e3546eae2161709
5
5
  SHA512:
6
- metadata.gz: 727d483949c944dd8720ec70b8f431b7350dc50828fc960475f6765e70a7058a432eb0532e449cf0d074637033f4de5f5ecf4bb23ee2b56d0d78c0c42cf2a414
7
- data.tar.gz: c8904aac7fd49cd8740594e577fe41fff1d9f6b7011a5216e79a339798c25417acb8d465a321e223c018ad1988f0622957a2b9880dbfb14e645310369c695e6c
6
+ metadata.gz: 5a9ff75cc9a3dd233f91fb78e1a058e6150a556ec68cb9e7b05b47d83531ab27a5a41c158619550a248f776855eaef2b1fba09c842b30c9fbee91c4259c8f109
7
+ data.tar.gz: bd99b617189740625eb8de20dad5cb23306080b26049b3c8d4646f3b5e8b568f0b26ee7645b226104e6e7ce5ed6ea7de2a100213725db28e4b6ebeaa8203870a
data/README.md CHANGED
@@ -24,6 +24,13 @@ With ruby-bandwidth you have access to the entire set of API methods including:
24
24
  * **Recording** - mamange user's recordings.
25
25
 
26
26
  Also you can work with Bandwidth XML using special types (in namespace `Bandwidth::Xml`).
27
+
28
+ ## Release Notes
29
+ | Version | Notes |
30
+ |:---|:---|
31
+ | 2.0.4 | Fixed SIP Headers fields for creating a call |
32
+ | 2.0.5 | Fixed SIP key names |
33
+
27
34
  ## Install
28
35
 
29
36
  Via rubygems:
@@ -154,7 +154,7 @@ module Bandwidth
154
154
  result = {}
155
155
  v.each do |k, val|
156
156
  if( k.to_s == 'sip_headers') # Don't camel case the sip headers, they probably start with X- which is required by the API to be upper case
157
- result[k.to_s()] = val
157
+ result[k.to_s().camelcase(:lower)] = val
158
158
  else
159
159
  result[k.to_s().camelcase(:lower)] = camelcase(val)
160
160
  end
@@ -1,4 +1,4 @@
1
1
  module Bandwidth
2
2
  # Version of this gem
3
- VERSION = "2.0.4"
3
+ VERSION = "2.0.5"
4
4
  end
@@ -32,10 +32,12 @@ describe Bandwidth::Call do
32
32
  end
33
33
 
34
34
  it 'should create a new item with the sip_headers' do
35
- raw_data = { :from => "from", :to => "to", :sip_headers => { "X-Header-1" => "header_1" } }
36
- client.stubs.post('/v1/users/userId/calls', raw_data.to_json.to_s) {|env| [201, {'Location' => '/v1/users/userId/calls/1'}, '']}
35
+ request_data = { :from => "from", :to => "to", :sip_headers => { "X-Header-1" => "header_1" } }
36
+ response_data = { :from => "from", :to => "to", :sipHeaders => { "X-Header-1" => "header_1" } }
37
+
38
+ client.stubs.post('/v1/users/userId/calls', response_data.to_json.to_s) {|env| [201, {'Location' => '/v1/users/userId/calls/1'}, '']}
37
39
  client.stubs.get('/v1/users/userId/calls/1') {|env| [200, {}, template_json]}
38
- expect(Call.create(client,raw_data).to_data()).to eql(template_item)
40
+ expect(Call.create(client,request_data).to_data()).to eql(template_item)
39
41
  end
40
42
 
41
43
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-bandwidth
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.0.4
4
+ version: 2.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Andrey Belchikov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-10-01 00:00:00.000000000 Z
11
+ date: 2019-10-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: builder