hobby-json 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,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6681daa3660fe33bc169a0d8ee9eae5ff2b3724d3b8a4f7a9d66f61864eff0c9
4
- data.tar.gz: 1d1c83b0529740a02b896bba002ab4c2f47b5c80ec3fe7353ea53dabe2f68e01
3
+ metadata.gz: 04bef8239f05fe122b05e258dbc95febb39e9ce6b2e73df1e721d035af989f95
4
+ data.tar.gz: 4defa4ae325347cdd8e98a7ee200276df901034b600bcec40bf577646fe6f5f1
5
5
  SHA512:
6
- metadata.gz: ac541875f2e93d174b2bc2f6be9068522028c130f10ab401e6d8c1a9ec93a5116a1255385218364481aba968783f83784f266f814eae954d6127c9518ae0d7f8
7
- data.tar.gz: 02cee90a78e8fa2c19fa1811d7578c7dd1d30721681c10186d15aa61c27e0749c212bcfa6d26a17a9ec6af1d1003d0c85f2f66e508e38d62f04e607a28164814
6
+ metadata.gz: e05c326717b42f847c14146b8de6be799d998b657a9a346d354fa327bee843437638f2365cc8cc91788b71dea85de81ae599992398861c0ee1bd10795d4daabb
7
+ data.tar.gz: fee3dfd8b473f628e178be95e903e40f91718a662b3242e258370cf649dc9e133bf1794095fa1905e7cf3df34574ec790c5538a0bf7531cfc0b9ccd67c9695ac
data/hobby-json.gemspec CHANGED
@@ -1,9 +1,9 @@
1
1
  Gem::Specification.new do |g|
2
2
  g.name = 'hobby-json'
3
3
  g.files = `git ls-files`.split($/)
4
- g.version = '0.0.5'
4
+ g.version = '0.0.6'
5
5
  g.summary = 'A Hobby extension for JSON requests and responses.'
6
- g.authors = ['Anatoly Chernow']
6
+ g.authors = ['Anatoly Chernov']
7
7
 
8
- g.add_dependency 'rack'
8
+ g.add_dependency 'hobby', '~> 0.2.2'
9
9
  end
data/lib/hobby/json.rb CHANGED
@@ -20,7 +20,7 @@ module Hobby
20
20
  ::JSON.parse request.body.read
21
21
  rescue
22
22
  response.status = 400
23
- throw :halt, response
23
+ halt
24
24
  end
25
25
  end
26
26
  end
@@ -0,0 +1,14 @@
1
+ - get:
2
+ path: /access_key
3
+ format: json
4
+ body:
5
+ key: some string
6
+ headers:
7
+ Content-Type: application/json
8
+
9
+ response:
10
+ status: 200
11
+ format: json
12
+ body: some string
13
+ headers.>:
14
+ Content-Type: application/json
metadata CHANGED
@@ -1,29 +1,29 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hobby-json
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
- - Anatoly Chernow
7
+ - Anatoly Chernov
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-05-24 00:00:00.000000000 Z
11
+ date: 2021-03-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: rack
14
+ name: hobby
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - ">="
17
+ - - "~>"
18
18
  - !ruby/object:Gem::Version
19
- version: '0'
19
+ version: 0.2.2
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - ">="
24
+ - - "~>"
25
25
  - !ruby/object:Gem::Version
26
- version: '0'
26
+ version: 0.2.2
27
27
  description:
28
28
  email:
29
29
  executables: []
@@ -38,6 +38,7 @@ files:
38
38
  - lib/hobby/json.rb
39
39
  - readme.adoc
40
40
  - spec/helper.rb
41
+ - spec/http/access_key.yml
41
42
  - spec/http/bad_request.yml
42
43
  - spec/http/bad_request_when_json_key_accessed.yml
43
44
  - spec/http/bad_request_when_wrong_content_type.yml
@@ -61,7 +62,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
61
62
  - !ruby/object:Gem::Version
62
63
  version: '0'
63
64
  requirements: []
64
- rubygems_version: 3.0.3
65
+ rubygems_version: 3.1.4
65
66
  signing_key:
66
67
  specification_version: 4
67
68
  summary: A Hobby extension for JSON requests and responses.