ruby-asterisk 0.0.5 → 0.0.6

Sign up to get free protection for your applications and to get access to all the features.
@@ -74,19 +74,19 @@ module RubyAsterisk
74
74
  _data[:hints].each do |hint|
75
75
  case hint["Status"]
76
76
  when "-1"
77
- hint["Status"] = "Extension not found"
77
+ hint["DescriptiveStatus"] = "Extension not found"
78
78
  when "0"
79
- hint["Status"] = "Idle"
79
+ hint["DescriptiveStatus"] = "Idle"
80
80
  when "1"
81
- hint["Status"] = "In Use"
81
+ hint["DescriptiveStatus"] = "In Use"
82
82
  when "2"
83
- hint["Status"] = "Busy"
83
+ hint["DescriptiveStatus"] = "Busy"
84
84
  when "4"
85
- hint["Status"] = "Unavailable"
85
+ hint["DescriptiveStatus"] = "Unavailable"
86
86
  when "8"
87
- hint["Status"] = "Ringing"
87
+ hint["DescriptiveStatus"] = "Ringing"
88
88
  when "16"
89
- hint["Status"] = "On Hold"
89
+ hint["DescriptiveStatus"] = "On Hold"
90
90
  end
91
91
  end
92
92
  _data
@@ -1,3 +1,3 @@
1
1
  module Rami
2
- VERSION = "0.0.5"
2
+ VERSION = "0.0.6"
3
3
  end
@@ -149,7 +149,8 @@ describe RubyAsterisk::Response do
149
149
 
150
150
  it "should correctly fill the fields" do
151
151
  @response = RubyAsterisk::Response.new("ExtensionState",extension_state_response)
152
- @response.data[:hints][0]["Status"].should eq("Idle")
152
+ @response.data[:hints][0]["Status"].should eq("0")
153
+ @response.data[:hints][0]["DescriptiveStatus"].should eq("Idle")
153
154
  end
154
155
  end
155
156
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: ruby-asterisk
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.5
5
+ version: 0.0.6
6
6
  platform: ruby
7
7
  authors:
8
8
  - Emiliano Della Casa