http_stub 0.14.0 → 0.14.1

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
  SHA1:
3
- metadata.gz: c1395ebc2f767907eec2d37cf8610cb85c63293a
4
- data.tar.gz: ae502b16f3a1ca9657c314c90289ba41ef08911d
3
+ metadata.gz: 31d1c854f7ef573f7ecba95433c5e8e9071fd783
4
+ data.tar.gz: 4ec87eef0e59c8a308672aa494a8aa6fc2ebcead
5
5
  SHA512:
6
- metadata.gz: c7f16c607745c0fd098b442a7f0132932a7c2981f7f6c452d4e59f1fa352c6f4829d49982b85e1399f04b1d2aebcfe64be3406fd8b440ba3f882cae11cd05994
7
- data.tar.gz: 5e70a3d3b209cb668e535292bdee87f4563aca05c64ce3c0f2e3ea9018d1def4e2ba43a063e549f067a7e5feb53deb3895a643f16628ad00fa8d4bcaa1f99092
6
+ metadata.gz: ee44d8c1f4a6bb65e77291236d050c23cd656277bfdf64ef8ef0db83311404e07c36f8f3afac46900d9a6ba8da64cc7863bef56243692ee195fa5d641db4cc9e
7
+ data.tar.gz: 60bad966b7b2536085745e91dbf583f8b93541b0f6f56e73cd6fc9c767b622e32959a32dc6db71be4d467bd6fa907605463bf4a0609a64a7d43f2c6a2d144ad2
@@ -4,12 +4,22 @@ module HttpStub
4
4
 
5
5
  class Omittable
6
6
 
7
- def self.format(value)
8
- value.is_a?(Hash) ? value.reduce({}) do |result, entry|
9
- key, value = entry
10
- result[key] = value == :omitted ? "control:omitted" : value
11
- result
12
- end : value
7
+ class << self
8
+
9
+ def format(value)
10
+ value.is_a?(Hash) ? format_hash(value) : value
11
+ end
12
+
13
+ private
14
+
15
+ def format_hash(value)
16
+ value.reduce({}) do |result, entry|
17
+ key, value = entry
18
+ result[key] = value == :omitted ? "control:omitted" : value
19
+ result
20
+ end
21
+ end
22
+
13
23
  end
14
24
 
15
25
  end
@@ -1,3 +1,3 @@
1
1
  module HttpStub
2
- VERSION = "0.14.0".freeze
2
+ VERSION = "0.14.1".freeze
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: http_stub
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.14.0
4
+ version: 0.14.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matthew Ueckerman
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2015-01-28 00:00:00.000000000 Z
12
+ date: 2015-03-24 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake
@@ -143,14 +143,14 @@ dependencies:
143
143
  requirements:
144
144
  - - "~>"
145
145
  - !ruby/object:Gem::Version
146
- version: '3.1'
146
+ version: '3.2'
147
147
  type: :development
148
148
  prerelease: false
149
149
  version_requirements: !ruby/object:Gem::Requirement
150
150
  requirements:
151
151
  - - "~>"
152
152
  - !ruby/object:Gem::Version
153
- version: '3.1'
153
+ version: '3.2'
154
154
  - !ruby/object:Gem::Dependency
155
155
  name: simplecov
156
156
  requirement: !ruby/object:Gem::Requirement
@@ -356,7 +356,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
356
356
  version: '0'
357
357
  requirements: []
358
358
  rubyforge_project: http_stub
359
- rubygems_version: 2.2.2
359
+ rubygems_version: 2.4.6
360
360
  signing_key:
361
361
  specification_version: 4
362
362
  summary: A HTTP Server replaying configured stub responses