opensips-mi 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- MWFhOGFlYTdhZTU4N2I1MDdjYzVkNDU4ZWE3MWM1MzgwOTJmNGYzMw==
4
+ NWU5ZWY5NzUwZDAwZjEyZmNmMDMxYmRlYzE5MDY4YTIzNDY2NzY4Mg==
5
5
  data.tar.gz: !binary |-
6
- ZjE5MWRkYmQ5MThiNGM4ZjdkY2QxYWMyYmMwMzc4ZjA4YjRjMDIyOA==
6
+ NTc0Y2MwZjI3YmExY2VlZjhiMDVhMjZlMjdhYmMyMjA5YjlmZTYyYg==
7
7
  !binary "U0hBNTEy":
8
8
  metadata.gz: !binary |-
9
- MDU0ODY2NGUwYTA4Y2RjM2M1NmJlMWRhNjJjZDcyMzgwNWM3OTdmMzZlOTcw
10
- ODU3M2JiY2IwYTNkYjk2ODlmNDYwOWVhYWMzYWI3NDdjZTVjNDFjMzM5MTFm
11
- YWM1NzMwYjkyZDUzMTY4NWQyYzM3Y2YzN2YzYzYwMGJjYWQzNjM=
9
+ NjkxOTI1Mzg4NjQ3N2ExN2M0MjMzMWM4NDZlYzRiNjlmNjY1MTBmZWRiYTE4
10
+ YzFkMmE0MGYwZWY4MTBlYjRkMjJmMWM2MGZjZmUzNDI0ZTUwNTNkOWE3OWM4
11
+ ZDZjOGEyYjZiZDFmNTQzZGNmOGFhODYwMGY5M2M3MzdhYTk0ZDI=
12
12
  data.tar.gz: !binary |-
13
- Yzc5NWMzYjYwZjQ1NzJiMzA1NDYzMzU4OGU4ODQ5ODUyZGFkNmE0Y2Y0MGQ4
14
- Y2Q1MDRlZWMyZmQ4YmFiZTkyM2ZlZTc3NjdmOGU3NjZiOTE3MmMyZTczYTM4
15
- NDdhNWFjNmNlNmY4OWI3NmZjNjFjNWZlNTBlZWI3MWFmZWEzYzM=
13
+ OGRiYTdkNGFiYzRkM2Q4MjdlMDU1NWMxZmNkNzFjM2E4ZDRkMjA5MzkwNzk3
14
+ MGFkODkzYzJjNmE4ZmU2NmFhYjIzZjc3OGM3OTQ0M2NhMjlmM2Q1ZDdmY2Uy
15
+ MDcxYjA4ZmI4MmQ1NWVkN2U2Y2FjZDkwNzE0OTA0MWY2YTQwMGU=
@@ -78,7 +78,7 @@ module Opensips
78
78
  #
79
79
  def uac_dlg method, ruri, hf, next_hop = ?., socket = ?., body = nil
80
80
  mandatory_hf = Array['To', 'From']
81
- mandatory_hf += ['Content-Type', 'Content-Length'] unless body.nil?
81
+ mandatory_hf += ['Content-Type'] unless body.nil?
82
82
  mandatory_hf.map{|h|h.downcase}.each do |n|
83
83
  raise ArgumentError,
84
84
  "Missing mandatory header #{n.capitalize}" unless hf.keys.map{|h| h.downcase}.include?(n)
@@ -151,7 +151,6 @@ module Opensips
151
151
  'Event' => "message-summary",
152
152
  'Subscription-State'=> "active",
153
153
  'Content-Type' => "application/simple-message-summary",
154
- 'Content-Length' => mbody.map{|k,v| "#{k}: #{v}"}.join("\r\n").length,
155
154
  'nl' => "",
156
155
  ]
157
156
 
@@ -1,5 +1,5 @@
1
1
  module Opensips
2
2
  module MI
3
- VERSION = "0.0.5"
3
+ VERSION = "0.0.6"
4
4
  end
5
5
  end
@@ -36,17 +36,6 @@ describe Command, "commands for transport classes" do
36
36
 
37
37
  end
38
38
 
39
- it "must raise when missing body mandatory headers" do
40
- mi = init_class_fifo
41
- ret = proc {
42
- mi.uac_dlg "NOTIFY",
43
- "sip:alice@wanderland.com",
44
- {"From" => "<sip:opensips>", "To" => "<sip:bob>", "content-type" => "xml"},
45
- ?., ?., "<body>Hello</body>"
46
- }.must_raise ArgumentError
47
- ret.message.must_match(/header Content-length/)
48
- end
49
-
50
39
  it "must have good parameters" do
51
40
  mi = init_class_fifo
52
41
  mi.expects(:command).with('t_uac_dlg', [
@@ -105,7 +94,6 @@ describe Command, "commands for transport classes" do
105
94
  'Event' => 'message-summary',
106
95
  'Subscription-State' => 'active',
107
96
  'Content-Type' => 'application/simple-message-summary',
108
- 'Content-Length' => 86,
109
97
  'nl' => '',
110
98
  'Messages-Waiting' => 'yes',
111
99
  'Message-Account' => 'sip:*97@asterisk.com',
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: opensips-mi
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.5
4
+ version: 0.0.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Stas Kobzar
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-06-27 00:00:00.000000000 Z
11
+ date: 2013-10-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -111,4 +111,3 @@ test_files:
111
111
  - test/test_command.rb
112
112
  - test/test_response.rb
113
113
  - test/test_transport.rb
114
- has_rdoc: