grape-roar 0.4.0 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +5 -5
- data/.github/FUNDING.yml +2 -0
- data/.github/dependabot.yml +6 -0
- data/.github/workflows/danger.yml +22 -0
- data/.github/workflows/lint.yml +15 -0
- data/.github/workflows/test-activerecord.yml +34 -0
- data/.github/workflows/test-mongodb.yml +33 -0
- data/.github/workflows/test.yml +19 -0
- data/.gitignore +1 -0
- data/.rspec +1 -0
- data/.rubocop.yml +6 -1
- data/.rubocop_todo.yml +181 -10
- data/CHANGELOG.md +20 -8
- data/Dangerfile +4 -0
- data/Gemfile +18 -7
- data/Gemfile.danger +6 -0
- data/README.md +255 -18
- data/Rakefile +3 -1
- data/grape-roar.gemspec +5 -3
- data/lib/grape/roar/decorator.rb +2 -0
- data/lib/grape/roar/extensions/relations/adapters/active_record.rb +35 -0
- data/lib/grape/roar/extensions/relations/adapters/base.rb +49 -0
- data/lib/grape/roar/extensions/relations/adapters/mongoid.rb +38 -0
- data/lib/grape/roar/extensions/relations/adapters.rb +22 -0
- data/lib/grape/roar/extensions/relations/dsl_methods.rb +86 -0
- data/lib/grape/roar/extensions/relations/exceptions.rb +14 -0
- data/lib/grape/roar/extensions/relations/mapper.rb +94 -0
- data/lib/grape/roar/extensions/relations/validations/active_record.rb +40 -0
- data/lib/grape/roar/extensions/relations/validations/misc.rb +18 -0
- data/lib/grape/roar/extensions/relations/validations/mongoid/6.rb +48 -0
- data/lib/grape/roar/extensions/relations/validations/mongoid/7.rb +75 -0
- data/lib/grape/roar/extensions/relations/validations/mongoid.rb +9 -0
- data/lib/grape/roar/extensions/relations/validations.rb +5 -0
- data/lib/grape/roar/extensions/relations.rb +23 -0
- data/lib/grape/roar/extensions.rb +3 -0
- data/lib/grape/roar/formatter.rb +2 -0
- data/lib/grape/roar/representer.rb +6 -1
- data/lib/grape/roar/version.rb +3 -1
- data/lib/grape/roar.rb +3 -0
- data/lib/grape-roar.rb +2 -0
- data/spec/config/mongoid.yml +6 -0
- data/spec/decorator_spec.rb +1 -1
- data/spec/extensions/relations/adapters/active_record_spec.rb +30 -0
- data/spec/extensions/relations/adapters/adapters_module_spec.rb +12 -0
- data/spec/extensions/relations/adapters/mongoid_spec.rb +30 -0
- data/spec/extensions/relations/dsl_methods_spec.rb +159 -0
- data/spec/extensions/relations/mapper_spec.rb +88 -0
- data/spec/extensions/relations/validations/active_record_spec.rb +49 -0
- data/spec/extensions/relations/validations/mongoid_spec.rb +91 -0
- data/spec/nested_representer_spec.rb +3 -14
- data/spec/present_with_spec.rb +2 -13
- data/spec/relations_spec.rb +77 -0
- data/spec/representer_spec.rb +36 -19
- data/spec/spec_helper.rb +19 -1
- data/spec/support/{article.rb → all/article.rb} +3 -1
- data/spec/support/{article_representer.rb → all/article_representer.rb} +3 -0
- data/spec/support/all/grape_app_context.rb +16 -0
- data/spec/support/{order.rb → all/order.rb} +3 -1
- data/spec/support/{order_representer.rb → all/order_representer.rb} +3 -1
- data/spec/support/{product.rb → all/product.rb} +2 -0
- data/spec/support/{product_representer.rb → all/product_representer.rb} +3 -1
- data/spec/support/{user.rb → all/user.rb} +2 -0
- data/spec/support/{user_representer.rb → all/user_representer.rb} +2 -0
- data/spec/support/mongoid/relational_models/cart.rb +7 -0
- data/spec/support/mongoid/relational_models/item.rb +7 -0
- data/spec/support/mongoid/relational_models/mongoid_cart_representer.rb +27 -0
- data/spec/support/mongoid/relational_models/mongoid_item_representer.rb +13 -0
- metadata +68 -17
- data/.travis.yml +0 -10
@@ -0,0 +1,91 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
if defined?(Mongoid)
|
4
|
+
describe Grape::Roar::Extensions::Relations::Validations::Mongoid, :mongoid do
|
5
|
+
let(:model_klass) { double }
|
6
|
+
let(:map_reflection) do
|
7
|
+
proc do |r|
|
8
|
+
case r
|
9
|
+
when /and/ then 'ManyToMany'
|
10
|
+
when /many/ then 'Many'
|
11
|
+
when /one/ then 'One'
|
12
|
+
when /belongs/ then 'In'
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
16
|
+
|
17
|
+
subject do
|
18
|
+
klass = Class.new do
|
19
|
+
def initialize(klass)
|
20
|
+
@klass = klass
|
21
|
+
end
|
22
|
+
|
23
|
+
attr_reader :klass
|
24
|
+
end
|
25
|
+
|
26
|
+
klass.include(described_class)
|
27
|
+
klass.new(model_klass)
|
28
|
+
end
|
29
|
+
|
30
|
+
before do
|
31
|
+
expect(model_klass).to receive(:reflect_on_association).twice do |r|
|
32
|
+
if r == :test_rel
|
33
|
+
if Gem::Version.new(Mongoid::VERSION) < Gem::Version.new('7')
|
34
|
+
{ relation: "Mongoid::Relations::#{relation_klass}::#{map_reflection.call(test_method)}".constantize }
|
35
|
+
else
|
36
|
+
{ relation: "Mongoid::Association::#{relation_klass}::#{test_method.to_s.camelize}".constantize }
|
37
|
+
end
|
38
|
+
else
|
39
|
+
{ relation: double }
|
40
|
+
end
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
context 'referenced' do
|
45
|
+
let(:relation_klass) { 'Referenced' }
|
46
|
+
|
47
|
+
%i[
|
48
|
+
belongs_to
|
49
|
+
has_and_belongs_to_many
|
50
|
+
has_many
|
51
|
+
has_one
|
52
|
+
].each do |test_method|
|
53
|
+
describe "##{test_method}_valid? validates the relation" do
|
54
|
+
let(:test_method) { test_method }
|
55
|
+
|
56
|
+
it 'properly validates the relation' do
|
57
|
+
expect(subject.send("#{test_method}_valid?", :test_rel)).to eql(true)
|
58
|
+
|
59
|
+
expect do
|
60
|
+
subject.send("#{test_method}_valid?", :fail)
|
61
|
+
end.to raise_error(
|
62
|
+
Grape::Roar::Extensions::Relations::
|
63
|
+
Exceptions::InvalidRelationError
|
64
|
+
)
|
65
|
+
end
|
66
|
+
end
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
context 'embedded' do
|
71
|
+
let(:relation_klass) { 'Embedded' }
|
72
|
+
|
73
|
+
%i[embeds_one embeds_many].each do |test_method|
|
74
|
+
describe "##{test_method}_valid? validates the relation" do
|
75
|
+
let(:test_method) { test_method }
|
76
|
+
|
77
|
+
it 'properly validates the relation' do
|
78
|
+
expect(subject.send("#{test_method}_valid?", :test_rel)).to eql(true)
|
79
|
+
|
80
|
+
expect do
|
81
|
+
subject.send("#{test_method}_valid?", :fail)
|
82
|
+
end.to raise_error(
|
83
|
+
Grape::Roar::Extensions::Relations::
|
84
|
+
Exceptions::InvalidRelationError
|
85
|
+
)
|
86
|
+
end
|
87
|
+
end
|
88
|
+
end
|
89
|
+
end
|
90
|
+
end
|
91
|
+
end
|
@@ -1,20 +1,9 @@
|
|
1
|
-
|
1
|
+
# frozen_string_literal: true
|
2
2
|
|
3
3
|
describe Grape::Roar do
|
4
|
-
subject do
|
5
|
-
Class.new(Grape::API)
|
6
|
-
end
|
7
|
-
|
8
|
-
before do
|
9
|
-
subject.format :json
|
10
|
-
subject.formatter :json, Grape::Formatter::Roar
|
11
|
-
end
|
12
|
-
|
13
|
-
def app
|
14
|
-
subject
|
15
|
-
end
|
16
|
-
|
17
4
|
context 'nested representer' do
|
5
|
+
include_context 'Grape API App'
|
6
|
+
|
18
7
|
before do
|
19
8
|
subject.get('/order/:id') do
|
20
9
|
order = Order.new(id: params[:id], client_id: 42)
|
data/spec/present_with_spec.rb
CHANGED
@@ -1,18 +1,7 @@
|
|
1
|
-
|
1
|
+
# frozen_string_literal: true
|
2
2
|
|
3
3
|
describe Grape::Roar do
|
4
|
-
|
5
|
-
Class.new(Grape::API)
|
6
|
-
end
|
7
|
-
|
8
|
-
before do
|
9
|
-
subject.format :json
|
10
|
-
subject.formatter :json, Grape::Formatter::Roar
|
11
|
-
end
|
12
|
-
|
13
|
-
def app
|
14
|
-
subject
|
15
|
-
end
|
4
|
+
include_context 'Grape API App'
|
16
5
|
|
17
6
|
context 'using present' do
|
18
7
|
before do
|
@@ -0,0 +1,77 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
describe Grape::Roar::Extensions::Relations do
|
4
|
+
describe '.included' do
|
5
|
+
subject { Class.new }
|
6
|
+
|
7
|
+
after { subject.include(described_class) }
|
8
|
+
|
9
|
+
it 'mixes DSLMethods into the singleton class of its target' do
|
10
|
+
expect(subject.singleton_class).to receive(:include).with(
|
11
|
+
Grape::Roar::Extensions::Relations::DSLMethods
|
12
|
+
)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
context 'with mongoid', :mongoid do
|
17
|
+
include_context 'Grape API App'
|
18
|
+
|
19
|
+
# Make sure Mongo is empty
|
20
|
+
before { Mongoid::Config.purge! }
|
21
|
+
|
22
|
+
let(:result) { JSON.parse(last_response.body) }
|
23
|
+
|
24
|
+
context 'has_many, embedded: false' do
|
25
|
+
before do
|
26
|
+
subject.get('/carts/:id') do
|
27
|
+
cart = Cart.create(id: params[:id])
|
28
|
+
Array.new(5).map { Item.create(cart: cart) }
|
29
|
+
present(cart, with: MongoidCartRepresenter)
|
30
|
+
end
|
31
|
+
|
32
|
+
get '/carts/1'
|
33
|
+
end
|
34
|
+
|
35
|
+
it 'correctly generates the self link' do
|
36
|
+
expect(result['_links']['self']['href']).to eql(
|
37
|
+
'http://example.org/carts/1'
|
38
|
+
)
|
39
|
+
end
|
40
|
+
|
41
|
+
it 'correctly generates links for items' do
|
42
|
+
expect(result['_links']['items'].map { |l| l['href'] }).to all(
|
43
|
+
match(%r{^http://example\.org/items/[A-Za-z0-9]*$})
|
44
|
+
)
|
45
|
+
end
|
46
|
+
end
|
47
|
+
|
48
|
+
context 'belongs_to, embedded: true' do
|
49
|
+
before do
|
50
|
+
subject.get('/items/:id') do
|
51
|
+
present(
|
52
|
+
Item.create(id: params[:id], cart: Cart.create),
|
53
|
+
with: MongoidItemRepresenter
|
54
|
+
)
|
55
|
+
end
|
56
|
+
|
57
|
+
get '/items/1'
|
58
|
+
end
|
59
|
+
|
60
|
+
it 'correctly generates the self link' do
|
61
|
+
expect(result['_links']['self']['href']).to eql(
|
62
|
+
'http://example.org/items/1'
|
63
|
+
)
|
64
|
+
end
|
65
|
+
|
66
|
+
it 'correctly represents the embedded cart' do
|
67
|
+
expect(result['_embedded']['cart']['_links']['self']['href'])
|
68
|
+
.to match(%r{^http://example\.org/carts/[A-Za-z0-9]*$})
|
69
|
+
|
70
|
+
expect(result['_embedded']['cart']['_links']['items'].count).to eql(1)
|
71
|
+
expect(result['_embedded']['cart']['_links']['items'].first).to eql(
|
72
|
+
result['_links']['self']
|
73
|
+
)
|
74
|
+
end
|
75
|
+
end
|
76
|
+
end
|
77
|
+
end
|
data/spec/representer_spec.rb
CHANGED
@@ -1,29 +1,46 @@
|
|
1
|
-
|
1
|
+
# frozen_string_literal: true
|
2
2
|
|
3
3
|
describe Grape::Roar do
|
4
|
-
|
5
|
-
Class.new(Grape::API)
|
6
|
-
end
|
7
|
-
|
8
|
-
before do
|
9
|
-
subject.format :json
|
10
|
-
subject.formatter :json, Grape::Formatter::Roar
|
11
|
-
end
|
12
|
-
|
13
|
-
def app
|
14
|
-
subject
|
15
|
-
end
|
4
|
+
include_context 'Grape API App'
|
16
5
|
|
17
6
|
context 'representer' do
|
18
|
-
|
19
|
-
|
20
|
-
|
7
|
+
context 'with a known model' do
|
8
|
+
before do
|
9
|
+
subject.get('/article/:id') do
|
10
|
+
Article.new(title: 'Lonestar', id: params[:id])
|
11
|
+
end
|
12
|
+
end
|
13
|
+
|
14
|
+
it 'returns a hypermedia representation' do
|
15
|
+
get '/article/666'
|
16
|
+
expect(last_response.body).to eq '{"title":"Lonestar","id":"666","links":[{"rel":"self","href":"/article/666"}]}'
|
21
17
|
end
|
22
18
|
end
|
23
19
|
|
24
|
-
|
25
|
-
|
26
|
-
|
20
|
+
context 'without an instance singleton' do
|
21
|
+
context 'as nil' do
|
22
|
+
before do
|
23
|
+
subject.get('/article/:id') do
|
24
|
+
present(nil, with: ArticleRepresenter)
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
it 'raises TypeError' do
|
29
|
+
expect { get '/article/666' }.to raise_error(TypeError)
|
30
|
+
end
|
31
|
+
end
|
32
|
+
|
33
|
+
context 'as another immediate value' do
|
34
|
+
before do
|
35
|
+
subject.get('/article/:id') do
|
36
|
+
present(5, with: ArticleRepresenter)
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
it 'raises TypeError' do
|
41
|
+
expect { get '/article/666' }.to raise_error(TypeError)
|
42
|
+
end
|
43
|
+
end
|
27
44
|
end
|
28
45
|
end
|
29
46
|
end
|
data/spec/spec_helper.rb
CHANGED
@@ -1,8 +1,16 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
$LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '..', 'lib'))
|
2
4
|
$LOAD_PATH.unshift(File.dirname(__FILE__))
|
3
5
|
|
6
|
+
require 'ostruct'
|
7
|
+
require 'bigdecimal'
|
8
|
+
require 'base64'
|
9
|
+
require 'logger'
|
10
|
+
|
4
11
|
require 'bundler'
|
5
12
|
Bundler.setup :default, :test
|
13
|
+
Bundler.require
|
6
14
|
|
7
15
|
require 'grape'
|
8
16
|
|
@@ -16,6 +24,16 @@ require 'rspec'
|
|
16
24
|
|
17
25
|
RSpec.configure do |config|
|
18
26
|
config.include Rack::Test::Methods
|
27
|
+
config.filter_run_excluding(
|
28
|
+
activerecord: true, mongoid: true
|
29
|
+
)
|
19
30
|
end
|
20
31
|
|
21
|
-
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
|
32
|
+
Dir["#{File.dirname(__FILE__)}/support/all/**/*.rb"].each { |f| require f }
|
33
|
+
|
34
|
+
# For Relational Extension Tests
|
35
|
+
if defined?(Mongoid)
|
36
|
+
ENV['MONGOID_ENV'] ||= 'test'
|
37
|
+
Mongoid.load!('./spec/config/mongoid.yml')
|
38
|
+
Dir["#{File.dirname(__FILE__)}/support/mongoid/**/*.rb"].each { |f| require f }
|
39
|
+
end
|
@@ -1,3 +1,5 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
1
3
|
require 'roar/json/hal'
|
2
4
|
|
3
5
|
module ProductRepresenter
|
@@ -10,6 +12,6 @@ module ProductRepresenter
|
|
10
12
|
|
11
13
|
link :self do |opts|
|
12
14
|
request = Grape::Request.new(opts[:env])
|
13
|
-
|
15
|
+
request.url.to_s
|
14
16
|
end
|
15
17
|
end
|
@@ -0,0 +1,27 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
module MongoidCartRepresenter
|
4
|
+
include Roar::JSON
|
5
|
+
include Roar::JSON::HAL
|
6
|
+
include Roar::Hypermedia
|
7
|
+
|
8
|
+
include Grape::Roar::Extensions::Relations
|
9
|
+
|
10
|
+
relation :has_many, :items
|
11
|
+
|
12
|
+
link_self
|
13
|
+
end
|
14
|
+
|
15
|
+
# Class style below, but want to test module
|
16
|
+
|
17
|
+
# class MongoidCartRepresenter < Grape::Roar::Decorator
|
18
|
+
# include Roar::JSON
|
19
|
+
# include Roar::JSON::HAL
|
20
|
+
# include Roar::Hypermedia
|
21
|
+
|
22
|
+
# include Grape::Roar::Extensions::Relations
|
23
|
+
|
24
|
+
# relation :has_many, :items
|
25
|
+
|
26
|
+
# link_self
|
27
|
+
# end
|
@@ -0,0 +1,13 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
class MongoidItemRepresenter < Grape::Roar::Decorator
|
4
|
+
include Roar::JSON
|
5
|
+
include Roar::JSON::HAL
|
6
|
+
include Roar::Hypermedia
|
7
|
+
|
8
|
+
include Grape::Roar::Extensions::Relations
|
9
|
+
|
10
|
+
relation :belongs_to, :cart, embedded: true
|
11
|
+
|
12
|
+
link_self
|
13
|
+
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: grape-roar
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.5.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Daniel Doubrovkine
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2025-09-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: grape
|
@@ -24,6 +24,20 @@ dependencies:
|
|
24
24
|
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
|
+
- !ruby/object:Gem::Dependency
|
28
|
+
name: multi_json
|
29
|
+
requirement: !ruby/object:Gem::Requirement
|
30
|
+
requirements:
|
31
|
+
- - ">="
|
32
|
+
- !ruby/object:Gem::Version
|
33
|
+
version: '0'
|
34
|
+
type: :runtime
|
35
|
+
prerelease: false
|
36
|
+
version_requirements: !ruby/object:Gem::Requirement
|
37
|
+
requirements:
|
38
|
+
- - ">="
|
39
|
+
- !ruby/object:Gem::Version
|
40
|
+
version: '0'
|
27
41
|
- !ruby/object:Gem::Dependency
|
28
42
|
name: roar
|
29
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -45,14 +59,22 @@ executables: []
|
|
45
59
|
extensions: []
|
46
60
|
extra_rdoc_files: []
|
47
61
|
files:
|
62
|
+
- ".github/FUNDING.yml"
|
63
|
+
- ".github/dependabot.yml"
|
64
|
+
- ".github/workflows/danger.yml"
|
65
|
+
- ".github/workflows/lint.yml"
|
66
|
+
- ".github/workflows/test-activerecord.yml"
|
67
|
+
- ".github/workflows/test-mongodb.yml"
|
68
|
+
- ".github/workflows/test.yml"
|
48
69
|
- ".gitignore"
|
49
70
|
- ".rspec"
|
50
71
|
- ".rubocop.yml"
|
51
72
|
- ".rubocop_todo.yml"
|
52
|
-
- ".travis.yml"
|
53
73
|
- CHANGELOG.md
|
54
74
|
- CONTRIBUTING.md
|
75
|
+
- Dangerfile
|
55
76
|
- Gemfile
|
77
|
+
- Gemfile.danger
|
56
78
|
- LICENSE
|
57
79
|
- README.md
|
58
80
|
- RELEASING.md
|
@@ -62,27 +84,57 @@ files:
|
|
62
84
|
- lib/grape-roar.rb
|
63
85
|
- lib/grape/roar.rb
|
64
86
|
- lib/grape/roar/decorator.rb
|
87
|
+
- lib/grape/roar/extensions.rb
|
88
|
+
- lib/grape/roar/extensions/relations.rb
|
89
|
+
- lib/grape/roar/extensions/relations/adapters.rb
|
90
|
+
- lib/grape/roar/extensions/relations/adapters/active_record.rb
|
91
|
+
- lib/grape/roar/extensions/relations/adapters/base.rb
|
92
|
+
- lib/grape/roar/extensions/relations/adapters/mongoid.rb
|
93
|
+
- lib/grape/roar/extensions/relations/dsl_methods.rb
|
94
|
+
- lib/grape/roar/extensions/relations/exceptions.rb
|
95
|
+
- lib/grape/roar/extensions/relations/mapper.rb
|
96
|
+
- lib/grape/roar/extensions/relations/validations.rb
|
97
|
+
- lib/grape/roar/extensions/relations/validations/active_record.rb
|
98
|
+
- lib/grape/roar/extensions/relations/validations/misc.rb
|
99
|
+
- lib/grape/roar/extensions/relations/validations/mongoid.rb
|
100
|
+
- lib/grape/roar/extensions/relations/validations/mongoid/6.rb
|
101
|
+
- lib/grape/roar/extensions/relations/validations/mongoid/7.rb
|
65
102
|
- lib/grape/roar/formatter.rb
|
66
103
|
- lib/grape/roar/representer.rb
|
67
104
|
- lib/grape/roar/version.rb
|
105
|
+
- spec/config/mongoid.yml
|
68
106
|
- spec/decorator_spec.rb
|
107
|
+
- spec/extensions/relations/adapters/active_record_spec.rb
|
108
|
+
- spec/extensions/relations/adapters/adapters_module_spec.rb
|
109
|
+
- spec/extensions/relations/adapters/mongoid_spec.rb
|
110
|
+
- spec/extensions/relations/dsl_methods_spec.rb
|
111
|
+
- spec/extensions/relations/mapper_spec.rb
|
112
|
+
- spec/extensions/relations/validations/active_record_spec.rb
|
113
|
+
- spec/extensions/relations/validations/mongoid_spec.rb
|
69
114
|
- spec/nested_representer_spec.rb
|
70
115
|
- spec/present_with_spec.rb
|
116
|
+
- spec/relations_spec.rb
|
71
117
|
- spec/representer_spec.rb
|
72
118
|
- spec/spec_helper.rb
|
73
|
-
- spec/support/article.rb
|
74
|
-
- spec/support/article_representer.rb
|
75
|
-
- spec/support/
|
76
|
-
- spec/support/
|
77
|
-
- spec/support/
|
78
|
-
- spec/support/
|
79
|
-
- spec/support/
|
80
|
-
- spec/support/
|
119
|
+
- spec/support/all/article.rb
|
120
|
+
- spec/support/all/article_representer.rb
|
121
|
+
- spec/support/all/grape_app_context.rb
|
122
|
+
- spec/support/all/order.rb
|
123
|
+
- spec/support/all/order_representer.rb
|
124
|
+
- spec/support/all/product.rb
|
125
|
+
- spec/support/all/product_representer.rb
|
126
|
+
- spec/support/all/user.rb
|
127
|
+
- spec/support/all/user_representer.rb
|
128
|
+
- spec/support/mongoid/relational_models/cart.rb
|
129
|
+
- spec/support/mongoid/relational_models/item.rb
|
130
|
+
- spec/support/mongoid/relational_models/mongoid_cart_representer.rb
|
131
|
+
- spec/support/mongoid/relational_models/mongoid_item_representer.rb
|
81
132
|
homepage: http://github.com/ruby-grape/grape-roar
|
82
133
|
licenses:
|
83
134
|
- MIT
|
84
|
-
metadata:
|
85
|
-
|
135
|
+
metadata:
|
136
|
+
rubygems_mfa_required: 'true'
|
137
|
+
post_install_message:
|
86
138
|
rdoc_options: []
|
87
139
|
require_paths:
|
88
140
|
- lib
|
@@ -97,9 +149,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
97
149
|
- !ruby/object:Gem::Version
|
98
150
|
version: '0'
|
99
151
|
requirements: []
|
100
|
-
|
101
|
-
|
102
|
-
signing_key:
|
152
|
+
rubygems_version: 3.5.16
|
153
|
+
signing_key:
|
103
154
|
specification_version: 4
|
104
155
|
summary: Enable Resource-Oriented Architectures in Grape API DSL
|
105
156
|
test_files: []
|