mirror of
https://github.com/ditkrg/active_model_serializers.git
synced 2026-01-22 22:06:50 +00:00
Update Rubocop
This commit is contained in:
parent
c97a80db95
commit
ec36ab7f60
19
.rubocop.yml
19
.rubocop.yml
@ -4,15 +4,20 @@ AllCops:
|
|||||||
Exclude:
|
Exclude:
|
||||||
- config/initializers/forbidden_yaml.rb
|
- config/initializers/forbidden_yaml.rb
|
||||||
- !ruby/regexp /(vendor|bundle|bin|db|tmp)\/.*/
|
- !ruby/regexp /(vendor|bundle|bin|db|tmp)\/.*/
|
||||||
RunRailsCops: true
|
|
||||||
DisplayCopNames: true
|
DisplayCopNames: true
|
||||||
DisplayStyleGuide: true
|
DisplayStyleGuide: true
|
||||||
|
|
||||||
|
Rails:
|
||||||
|
Enabled: true
|
||||||
|
|
||||||
Lint/NestedMethodDefinition:
|
Lint/NestedMethodDefinition:
|
||||||
Enabled: false
|
Enabled: false
|
||||||
Exclude:
|
Exclude:
|
||||||
- test/action_controller/serialization_test.rb
|
- test/action_controller/serialization_test.rb
|
||||||
|
|
||||||
|
Style/Alias:
|
||||||
|
EnforcedStyle: prefer_alias
|
||||||
|
|
||||||
Style/StringLiterals:
|
Style/StringLiterals:
|
||||||
EnforcedStyle: single_quotes
|
EnforcedStyle: single_quotes
|
||||||
|
|
||||||
@ -59,6 +64,18 @@ Style/BlockDelimiters:
|
|||||||
Enabled: true
|
Enabled: true
|
||||||
EnforcedStyle: line_count_based
|
EnforcedStyle: line_count_based
|
||||||
|
|
||||||
|
Style/SignalException:
|
||||||
|
EnforcedStyle: semantic
|
||||||
|
|
||||||
|
Style/TrailingCommaInLiteral:
|
||||||
|
EnforcedStyleForMultiline: no_comma
|
||||||
|
|
||||||
|
Style/ConditionalAssignment:
|
||||||
|
Enabled: false
|
||||||
|
|
||||||
|
Style/DotPosition:
|
||||||
|
EnforcedStyle: leading
|
||||||
|
|
||||||
########## test_helper.rb sanity
|
########## test_helper.rb sanity
|
||||||
Style/EndBlock:
|
Style/EndBlock:
|
||||||
Exclude:
|
Exclude:
|
||||||
|
|||||||
@ -177,14 +177,6 @@ Style/Semicolon:
|
|||||||
Exclude:
|
Exclude:
|
||||||
- 'lib/active_model/serializer/fieldset.rb'
|
- 'lib/active_model/serializer/fieldset.rb'
|
||||||
|
|
||||||
# Offense count: 3
|
|
||||||
# Cop supports --auto-correct.
|
|
||||||
# Configuration parameters: EnforcedStyle, SupportedStyles.
|
|
||||||
Style/SignalException:
|
|
||||||
Exclude:
|
|
||||||
- 'lib/active_model/serializer/fieldset.rb'
|
|
||||||
- 'lib/active_model/serializer/pass_through_serializer.rb'
|
|
||||||
|
|
||||||
# Offense count: 1
|
# Offense count: 1
|
||||||
# Cop supports --auto-correct.
|
# Cop supports --auto-correct.
|
||||||
# Configuration parameters: AllowIfMethodIsEmpty.
|
# Configuration parameters: AllowIfMethodIsEmpty.
|
||||||
@ -223,16 +215,6 @@ Style/TrailingBlankLines:
|
|||||||
- 'test/serializers/cache_test.rb'
|
- 'test/serializers/cache_test.rb'
|
||||||
- 'test/serializers/fieldset_test.rb'
|
- 'test/serializers/fieldset_test.rb'
|
||||||
|
|
||||||
# Offense count: 5
|
|
||||||
# Cop supports --auto-correct.
|
|
||||||
# Configuration parameters: EnforcedStyleForMultiline, SupportedStyles.
|
|
||||||
Style/TrailingComma:
|
|
||||||
Exclude:
|
|
||||||
- 'test/action_controller/adapter_selector_test.rb'
|
|
||||||
- 'test/action_controller/serialization_test.rb'
|
|
||||||
- 'test/adapter/json_api/belongs_to_test.rb'
|
|
||||||
- 'test/adapter/json_api/linked_test.rb'
|
|
||||||
|
|
||||||
# Offense count: 1
|
# Offense count: 1
|
||||||
Style/UnlessElse:
|
Style/UnlessElse:
|
||||||
Exclude:
|
Exclude:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user