gris 0.4.6 → 0.4.7

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 034350c7d90aff8466b08aff40fb6e9dafe967c7
4
- data.tar.gz: 7c9390ef0aeea7537d8da9d0688a930cf9aa0150
3
+ metadata.gz: baf6e7fb8bfc35fe35e8bdd84f973ffd239306c3
4
+ data.tar.gz: 655b2b8bdbb97fb442f794c6cb550d235c351a28
5
5
  SHA512:
6
- metadata.gz: 606f7d968a885ff8ea1c3665169aabd2de08ea75c4b72ce19f57b5098c72a4087cf5536e8e3daba233abc5b6d9afa5050601daafbe67651639b5c82ade73bcfa
7
- data.tar.gz: 97ceee9239f360daf0d4ba61a3a8677549626667b48ac0f0ef51f040759458210dcbe550539ea368fe6f76d246c58e5c5946b2d42dc08c339ad85cf84b9f9663
6
+ metadata.gz: 60a27cf6ac36461e47a3f8a06f2785e4ad07fc461deaae7791e8eb40751847791a36f8822316de8529946c5ee1cec408ec8374b419c6d4a30d30a7d74e301bff
7
+ data.tar.gz: e42765faf069b860feeec35d85c4903b9e681698d75744e9ed7a943cedbe3e6cd92baac8daea41e6e7afa2ac96e3e88e76476e92d1d9a3b4fb97d29f1ba1d917
@@ -1,5 +1,6 @@
1
- # This configuration was generated by `rubocop --auto-gen-config`
2
- # on 2015-08-17 12:39:38 -0400 using RuboCop version 0.31.0.
1
+ # This configuration was generated by
2
+ # `rubocop --auto-gen-config`
3
+ # on 2015-08-21 11:50:50 -0400 using RuboCop version 0.33.0.
3
4
  # The point is for the user to remove these configuration records
4
5
  # one by one as the offenses are removed from the code base.
5
6
  # Note that changes in the inspected code, or installation of new
@@ -11,49 +12,66 @@
11
12
  Lint/EndAlignment:
12
13
  Enabled: false
13
14
 
14
- # Offense count: 6
15
+ # Offense count: 2
16
+ Lint/NestedMethodDefinition:
17
+ Exclude:
18
+ - 'lib/gris/output_formatters/paginated_presenter.rb'
19
+
20
+ # Offense count: 5
15
21
  Metrics/AbcSize:
16
- Max: 33
22
+ Max: 38
17
23
 
18
24
  # Offense count: 1
19
25
  # Configuration parameters: CountComments.
20
26
  Metrics/ClassLength:
21
27
  Max: 112
22
28
 
23
- # Offense count: 2
29
+ # Offense count: 3
24
30
  Metrics/CyclomaticComplexity:
25
31
  Max: 11
26
32
 
27
- # Offense count: 74
33
+ # Offense count: 83
28
34
  # Configuration parameters: AllowURI, URISchemes.
29
35
  Metrics/LineLength:
30
36
  Max: 159
31
37
 
32
- # Offense count: 11
38
+ # Offense count: 9
33
39
  # Configuration parameters: CountComments.
34
40
  Metrics/MethodLength:
35
- Max: 33
41
+ Max: 32
36
42
 
37
43
  # Offense count: 16
44
+ # Cop supports --auto-correct.
38
45
  # Configuration parameters: IndentWhenRelativeTo, SupportedStyles, IndentOneStep.
39
46
  Style/CaseIndentation:
40
47
  Enabled: false
41
48
 
42
- # Offense count: 27
49
+ # Offense count: 29
43
50
  Style/Documentation:
44
51
  Enabled: false
45
52
 
46
- # Offense count: 1
53
+ # Offense count: 2
47
54
  Style/DoubleNegation:
48
- Enabled: false
55
+ Exclude:
56
+ - 'lib/gris/generators/migration_generator.rb'
57
+ - 'lib/gris/output_formatters/presenter_link_helpers.rb'
49
58
 
50
59
  # Offense count: 2
51
60
  # Configuration parameters: NamePrefix, NamePrefixBlacklist.
52
61
  Style/PredicateName:
53
- Enabled: false
62
+ Exclude:
63
+ - 'lib/gris/generators/migration_generator.rb'
54
64
 
55
65
  # Offense count: 1
56
66
  # Cop supports --auto-correct.
57
67
  # Configuration parameters: MultiSpaceAllowedForOperators.
58
68
  Style/SpaceAroundOperators:
59
- Enabled: false
69
+ Exclude:
70
+ - 'gris.gemspec'
71
+
72
+ # Offense count: 2
73
+ # Cop supports --auto-correct.
74
+ # Configuration parameters: ExactNameMatch, AllowPredicates, AllowDSLWriters, IgnoreClassMethods, Whitelist.
75
+ Style/TrivialAccessors:
76
+ Exclude:
77
+ - 'lib/gris/generators/migration_generator.rb'
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- gris (0.4.6)
4
+ gris (0.4.7)
5
5
  activesupport (~> 4.2, >= 4.2.0)
6
6
  chronic (~> 0.10.0)
7
7
  dalli (~> 2.7)
@@ -20,14 +20,14 @@ PATH
20
20
  GEM
21
21
  remote: https://rubygems.org/
22
22
  specs:
23
- activemodel (4.2.2)
24
- activesupport (= 4.2.2)
23
+ activemodel (4.2.3)
24
+ activesupport (= 4.2.3)
25
25
  builder (~> 3.1)
26
- activerecord (4.2.2)
27
- activemodel (= 4.2.2)
28
- activesupport (= 4.2.2)
26
+ activerecord (4.2.3)
27
+ activemodel (= 4.2.3)
28
+ activesupport (= 4.2.3)
29
29
  arel (~> 6.0)
30
- activesupport (4.2.2)
30
+ activesupport (4.2.3)
31
31
  i18n (~> 0.7)
32
32
  json (~> 1.7, >= 1.7.7)
33
33
  minitest (~> 5.1)
@@ -36,24 +36,22 @@ GEM
36
36
  acts_as_fu (0.0.9)
37
37
  activerecord
38
38
  sqlite3
39
- arel (6.0.0)
40
- ast (2.0.0)
41
- astrolabe (1.3.0)
42
- parser (>= 2.2.0.pre.3, < 3.0)
39
+ arel (6.0.3)
40
+ ast (2.1.0)
41
+ astrolabe (1.3.1)
42
+ parser (~> 2.2)
43
43
  axiom-types (0.1.1)
44
44
  descendants_tracker (~> 0.0.4)
45
45
  ice_nine (~> 0.11.0)
46
46
  thread_safe (~> 0.3, >= 0.3.1)
47
47
  builder (3.2.2)
48
- byebug (5.0.0)
49
- columnize (= 0.9.0)
48
+ byebug (6.0.2)
50
49
  childprocess (0.5.6)
51
50
  ffi (~> 1.0, >= 1.0.11)
52
51
  chronic (0.10.2)
53
52
  coercible (1.0.0)
54
53
  descendants_tracker (~> 0.0.1)
55
54
  colorize (0.7.7)
56
- columnize (0.9.0)
57
55
  dalli (2.7.4)
58
56
  descendants_tracker (0.0.4)
59
57
  thread_safe (~> 0.3, >= 0.3.1)
@@ -67,12 +65,12 @@ GEM
67
65
  net-http-digest_auth (~> 1.4)
68
66
  faraday_hal_middleware (0.0.1)
69
67
  faraday_middleware (>= 0.9, < 0.10)
70
- faraday_middleware (0.9.1)
68
+ faraday_middleware (0.9.2)
71
69
  faraday (>= 0.7.4, < 0.10)
72
- fasterer (0.1.9)
70
+ fasterer (0.1.11)
73
71
  colorize (~> 0.7)
74
72
  ruby_parser (~> 3.6)
75
- ffi (1.9.8)
73
+ ffi (1.9.10)
76
74
  futuroscope (0.1.11)
77
75
  git (1.2.9.1)
78
76
  grape (0.13.0)
@@ -97,7 +95,7 @@ GEM
97
95
  hashie (3.4.2)
98
96
  hashie-forbidden_attributes (0.1.1)
99
97
  hashie (>= 3.0)
100
- hyperclient (0.7.0)
98
+ hyperclient (0.7.1)
101
99
  faraday (~> 0.8)
102
100
  faraday-digestauth (~> 0.2)
103
101
  faraday_hal_middleware (~> 0.0.1)
@@ -119,7 +117,7 @@ GEM
119
117
  multi_xml (0.5.5)
120
118
  multipart-post (2.0.0)
121
119
  net-http-digest_auth (1.4)
122
- parser (2.2.2.5)
120
+ parser (2.2.2.6)
123
121
  ast (>= 1.1, < 3.0)
124
122
  powerpack (0.1.1)
125
123
  rack (1.6.4)
@@ -138,27 +136,27 @@ GEM
138
136
  uber (~> 0.0.7)
139
137
  roar (1.0.1)
140
138
  representable (>= 2.0.1, <= 3.0.0)
141
- rspec (3.2.0)
142
- rspec-core (~> 3.2.0)
143
- rspec-expectations (~> 3.2.0)
144
- rspec-mocks (~> 3.2.0)
145
- rspec-core (3.2.3)
146
- rspec-support (~> 3.2.0)
147
- rspec-expectations (3.2.1)
139
+ rspec (3.3.0)
140
+ rspec-core (~> 3.3.0)
141
+ rspec-expectations (~> 3.3.0)
142
+ rspec-mocks (~> 3.3.0)
143
+ rspec-core (3.3.2)
144
+ rspec-support (~> 3.3.0)
145
+ rspec-expectations (3.3.1)
148
146
  diff-lcs (>= 1.2.0, < 2.0)
149
- rspec-support (~> 3.2.0)
150
- rspec-mocks (3.2.1)
147
+ rspec-support (~> 3.3.0)
148
+ rspec-mocks (3.3.2)
151
149
  diff-lcs (>= 1.2.0, < 2.0)
152
- rspec-support (~> 3.2.0)
153
- rspec-support (3.2.2)
154
- rubocop (0.31.0)
150
+ rspec-support (~> 3.3.0)
151
+ rspec-support (3.3.0)
152
+ rubocop (0.33.0)
155
153
  astrolabe (~> 1.3)
156
- parser (>= 2.2.2.1, < 3.0)
154
+ parser (>= 2.2.2.5, < 3.0)
157
155
  powerpack (~> 0.1)
158
156
  rainbow (>= 1.99.1, < 3.0)
159
157
  ruby-progressbar (~> 1.4)
160
158
  ruby-progressbar (1.7.5)
161
- ruby_parser (3.7.0)
159
+ ruby_parser (3.7.1)
162
160
  sexp_processor (~> 4.1)
163
161
  sexp_processor (4.6.0)
164
162
  sqlite3 (1.3.10)
@@ -187,5 +185,8 @@ DEPENDENCIES
187
185
  fasterer
188
186
  gris!
189
187
  hyperclient
190
- rspec (~> 3.2)
188
+ rspec (~> 3.3)
191
189
  rubocop
190
+
191
+ BUNDLED WITH
192
+ 1.10.6
@@ -34,7 +34,7 @@ Gem::Specification.new do |s|
34
34
  s.add_runtime_dependency 'indefinite_article', '~> 0.2'
35
35
 
36
36
  s.add_development_dependency 'bundler', '~> 1'
37
- s.add_development_dependency 'rspec', '~> 3.2'
37
+ s.add_development_dependency 'rspec', '~> 3.3'
38
38
  s.add_development_dependency 'rubocop', '~> 0.29'
39
39
  s.add_development_dependency 'activerecord', '~> 4.2'
40
40
  s.add_development_dependency 'acts_as_fu', '~> 0'
@@ -31,7 +31,7 @@ module Gris
31
31
  def append_endpoint_to_application_endpoint
32
32
  say 'Mounting new endpoint on ApplicationEndpoint.'
33
33
  insert_into_file path_to_application_endpoint, after: "# Additional mounted endpoints\n" do
34
- text = " mount #{name.classify.pluralize}Endpoint\n"
34
+ text = " mount #{name.classify.pluralize}Endpoint\n"
35
35
  text
36
36
  end
37
37
  end
@@ -24,7 +24,11 @@ module Gris
24
24
 
25
25
  private
26
26
 
27
- # replace the page parameter in the query string
27
+ def request_url(opts)
28
+ request = Grape::Request.new(opts[:env])
29
+ "#{request.base_url}#{opts[:env]['PATH_INFO']}"
30
+ end
31
+
28
32
  def query_string_for_page(page, opts)
29
33
  qs = Rack::Utils.parse_nested_query(opts[:env]['QUERY_STRING'])
30
34
  qs['page'] = page
@@ -10,13 +10,6 @@ module Gris
10
10
  include Roar::Hypermedia
11
11
  include Grape::Roar::Representer
12
12
  include Gris::PresenterLinkHelpers
13
-
14
- private
15
-
16
- def request_url(opts)
17
- request = Grape::Request.new(opts[:env])
18
- "#{request.base_url}#{opts[:env]['PATH_INFO']}"
19
- end
20
13
  end
21
14
  end
22
15
  end
@@ -1,5 +1,5 @@
1
1
  module Gris
2
- VERSION = '0.4.6'
2
+ VERSION = '0.4.7'
3
3
 
4
4
  class Version
5
5
  class << self
@@ -35,7 +35,7 @@ describe Gris::PresenterLinkHelpers do
35
35
  end
36
36
 
37
37
  it 'includes Gris::PresenterLinkHelpers' do
38
- expect(RootPresenter).to include(Gris::PresenterLinkHelpers)
38
+ expect(MyRootPresenter).to include(Gris::PresenterLinkHelpers)
39
39
  end
40
40
 
41
41
  it 'returns uri template for resource_links with additional arguments' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gris
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.4.6
4
+ version: 0.4.7
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dylan Fareed
@@ -256,14 +256,14 @@ dependencies:
256
256
  requirements:
257
257
  - - "~>"
258
258
  - !ruby/object:Gem::Version
259
- version: '3.2'
259
+ version: '3.3'
260
260
  type: :development
261
261
  prerelease: false
262
262
  version_requirements: !ruby/object:Gem::Requirement
263
263
  requirements:
264
264
  - - "~>"
265
265
  - !ruby/object:Gem::Version
266
- version: '3.2'
266
+ version: '3.3'
267
267
  - !ruby/object:Gem::Dependency
268
268
  name: rubocop
269
269
  requirement: !ruby/object:Gem::Requirement