haveapi 0.5.1 → 0.5.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG +5 -0
- data/haveapi.gemspec +2 -1
- data/lib/haveapi/server.rb +1 -1
- data/lib/haveapi/version.rb +1 -1
- data/lib/haveapi.rb +3 -1
- data/spec/params_spec.rb +3 -3
- metadata +16 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8579fbd8dd467b3248bba5d3cd8cbb46c889621b
|
4
|
+
data.tar.gz: 12fa89e290d89ea301123f66ca86e6bfc19c4785
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f406e97a08f0ae4c4b0fb6dab2114a36208f8ef6190f5480b9a86765dc97005ddf866402674164ae96d36f989e6ea40ed5f6e2e75d56a442751cf2e4e9613c0f
|
7
|
+
data.tar.gz: 2f5d0ebae55c055ac725097260b2fecbea6903b74d7927fc723186e6bacf708376a6cce978bea15c6594c44302e6d7547bc226f8a46f5d863417a9d7cc989a8c
|
data/CHANGELOG
CHANGED
data/haveapi.gemspec
CHANGED
@@ -5,7 +5,7 @@ require 'haveapi/version'
|
|
5
5
|
Gem::Specification.new do |s|
|
6
6
|
s.name = 'haveapi'
|
7
7
|
s.version = HaveAPI::VERSION
|
8
|
-
s.date = '2016-
|
8
|
+
s.date = '2016-03-03'
|
9
9
|
s.summary =
|
10
10
|
s.description = 'Framework for creating self-describing APIs'
|
11
11
|
s.authors = 'Jakub Skokan'
|
@@ -17,6 +17,7 @@ Gem::Specification.new do |s|
|
|
17
17
|
|
18
18
|
s.add_runtime_dependency 'require_all'
|
19
19
|
s.add_runtime_dependency 'json'
|
20
|
+
s.add_runtime_dependency 'activesupport', '~> 4.1.14'
|
20
21
|
s.add_runtime_dependency 'sinatra', '~> 1.4.6'
|
21
22
|
s.add_runtime_dependency 'tilt', '~> 1.4.1'
|
22
23
|
s.add_runtime_dependency 'redcarpet', '~> 3.3.4'
|
data/lib/haveapi/server.rb
CHANGED
data/lib/haveapi/version.rb
CHANGED
data/lib/haveapi.rb
CHANGED
@@ -1,11 +1,13 @@
|
|
1
|
-
ar =
|
1
|
+
ar = Object.const_defined?(:ActiveRecord)
|
2
2
|
|
3
3
|
require 'require_all'
|
4
|
+
require 'active_support/inflector'
|
4
5
|
require 'active_record' if ar
|
5
6
|
require 'sinatra/base'
|
6
7
|
require 'sinatra/activerecord' if ar
|
7
8
|
require 'pp'
|
8
9
|
require 'github/markdown'
|
10
|
+
require 'json'
|
9
11
|
|
10
12
|
module HaveAPI
|
11
13
|
module Actions
|
data/spec/params_spec.rb
CHANGED
@@ -183,8 +183,8 @@ describe HaveAPI::Params do
|
|
183
183
|
string :param2
|
184
184
|
end)
|
185
185
|
p.exec
|
186
|
-
|
187
|
-
expect(p[:param1]).to eq(p.params
|
188
|
-
expect(p[:param2]).to eq(p.params
|
186
|
+
|
187
|
+
expect(p[:param1]).to eq(p.params[0])
|
188
|
+
expect(p[:param2]).to eq(p.params[1])
|
189
189
|
end
|
190
190
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: haveapi
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.5.
|
4
|
+
version: 0.5.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jakub Skokan
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-
|
11
|
+
date: 2016-03-03 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: require_all
|
@@ -38,6 +38,20 @@ dependencies:
|
|
38
38
|
- - '>='
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
|
+
- !ruby/object:Gem::Dependency
|
42
|
+
name: activesupport
|
43
|
+
requirement: !ruby/object:Gem::Requirement
|
44
|
+
requirements:
|
45
|
+
- - ~>
|
46
|
+
- !ruby/object:Gem::Version
|
47
|
+
version: 4.1.14
|
48
|
+
type: :runtime
|
49
|
+
prerelease: false
|
50
|
+
version_requirements: !ruby/object:Gem::Requirement
|
51
|
+
requirements:
|
52
|
+
- - ~>
|
53
|
+
- !ruby/object:Gem::Version
|
54
|
+
version: 4.1.14
|
41
55
|
- !ruby/object:Gem::Dependency
|
42
56
|
name: sinatra
|
43
57
|
requirement: !ruby/object:Gem::Requirement
|