Add rubocop spacing rules
We were following these rules in most places; we just didn't define them anywhere.
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
---
|
||||
linters:
|
||||
ExtraNewline:
|
||||
enabled: true
|
||||
FinalNewline:
|
||||
enabled: true
|
||||
SelfClosingTag:
|
||||
@@ -16,5 +18,27 @@ linters:
|
||||
enabled: true
|
||||
only:
|
||||
- Layout/EndOfLine
|
||||
- Layout/SpaceAfterColon
|
||||
- Layout/SpaceAfterComma
|
||||
- Layout/SpaceAfterMethodName
|
||||
- Layout/SpaceAfterNot
|
||||
- Layout/SpaceAfterSemicolon
|
||||
- Layout/SpaceAroundBlockParameters
|
||||
- Layout/SpaceAroundOperators
|
||||
- Layout/SpaceBeforeBlockBraces
|
||||
- Layout/SpaceBeforeComma
|
||||
- Layout/SpaceBeforeComment
|
||||
- Layout/SpaceBeforeFirstArg
|
||||
- Layout/SpaceBeforeSemicolon
|
||||
- Layout/SpaceInsideArrayLiteralBrackets
|
||||
- Layout/SpaceInsideArrayPercentLiteral
|
||||
- Layout/SpaceInsideBlockBraces
|
||||
- Layout/SpaceInsideHashLiteralBraces
|
||||
- Layout/SpaceInsideParens
|
||||
- Layout/SpaceInsidePercentLiteralDelimiters
|
||||
- Layout/SpaceInsideRangeLiteral
|
||||
- Layout/SpaceInsideReferenceBrackets
|
||||
- Layout/SpaceInsideStringInterpolation
|
||||
- Layout/Tab
|
||||
- Lint/LiteralAsCondition
|
||||
- Style/PercentLiteralDelimiters
|
||||
|
||||
@@ -32,6 +32,73 @@ Layout/EmptyLines:
|
||||
Layout/EndOfLine:
|
||||
EnforcedStyle: lf
|
||||
|
||||
Layout/SpaceAfterColon:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceAfterComma:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceAfterMethodName:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceAfterNot:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceAfterSemicolon:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceAroundBlockParameters:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceAroundOperators:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceBeforeBlockBraces:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceBeforeComma:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceBeforeComment:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceBeforeFirstArg:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceBeforeSemicolon:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideArrayLiteralBrackets:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideArrayPercentLiteral:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideBlockBraces:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideHashLiteralBraces:
|
||||
Enabled: true
|
||||
EnforcedStyle: compact
|
||||
|
||||
Layout/SpaceInsideParens:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsidePercentLiteralDelimiters:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideRangeLiteral:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideReferenceBrackets:
|
||||
Enabled: true
|
||||
|
||||
Layout/SpaceInsideStringInterpolation:
|
||||
Enabled: true
|
||||
|
||||
Layout/Tab:
|
||||
Enabled: true
|
||||
|
||||
Layout/TrailingBlankLines:
|
||||
Enabled: true
|
||||
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
shared_examples "documentable" do |documentable_factory_name,
|
||||
documentable_path,
|
||||
documentable_path_arguments|
|
||||
shared_examples "documentable" do |documentable_factory_name, documentable_path, documentable_path_arguments|
|
||||
include ActionView::Helpers
|
||||
|
||||
let(:administrator) { create(:user) }
|
||||
|
||||
@@ -1,6 +1,4 @@
|
||||
shared_examples "imageable destroy" do |imageable_factory_name,
|
||||
imageable_path,
|
||||
imageable_path_arguments|
|
||||
shared_examples "imageable destroy" do |imageable_factory_name, imageable_path, imageable_path_arguments|
|
||||
include ActionView::Helpers
|
||||
include ImagesHelper
|
||||
include ImageablesHelper
|
||||
|
||||
@@ -1,10 +1,4 @@
|
||||
shared_examples "mappable" do |mappable_factory_name,
|
||||
mappable_association_name,
|
||||
mappable_new_path,
|
||||
mappable_edit_path,
|
||||
mappable_show_path,
|
||||
mappable_path_arguments,
|
||||
management = false|
|
||||
shared_examples "mappable" do |mappable_factory_name, mappable_association_name, mappable_new_path, mappable_edit_path, mappable_show_path, mappable_path_arguments, management = false|
|
||||
|
||||
include ActionView::Helpers
|
||||
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
shared_examples "nested documentable" do |login_as_name, documentable_factory_name,
|
||||
path, documentable_path_arguments,
|
||||
fill_resource_method_name, submit_button,
|
||||
documentable_success_notice|
|
||||
shared_examples "nested documentable" do |login_as_name, documentable_factory_name, path, documentable_path_arguments, fill_resource_method_name, submit_button, documentable_success_notice|
|
||||
include ActionView::Helpers
|
||||
include DocumentsHelper
|
||||
include DocumentablesHelper
|
||||
|
||||
@@ -1,7 +1,4 @@
|
||||
shared_examples "nested imageable" do |imageable_factory_name, path,
|
||||
imageable_path_arguments, fill_resource_method_name,
|
||||
submit_button, imageable_success_notice,
|
||||
has_many_images = false|
|
||||
shared_examples "nested imageable" do |imageable_factory_name, path, imageable_path_arguments, fill_resource_method_name, submit_button, imageable_success_notice, has_many_images = false|
|
||||
include ActionView::Helpers
|
||||
include ImagesHelper
|
||||
include ImageablesHelper
|
||||
|
||||
Reference in New Issue
Block a user