mirror of
https://github.com/thoughtbot/factory_bot_rails.git
synced 2022-11-09 11:49:18 -05:00
124c89b264
This partially addresses #293. Since rubocop generated quite a few todos, the commits addressing them are split up into a few different PRs that cover different files.
138 lines
4 KiB
YAML
138 lines
4 KiB
YAML
inherit_from:
|
|
- https://raw.githubusercontent.com/thoughtbot/guides/master/style/ruby/.rubocop.yml
|
|
|
|
AllCops:
|
|
Exclude:
|
|
- "tmp/**/*"
|
|
|
|
Style/EmptyMethod:
|
|
EnforcedStyle: expanded
|
|
|
|
# TODO:
|
|
# This configuration was generated by
|
|
# `rubocop --auto-gen-config`
|
|
# on 2018-09-17 20:19:38 -0400 using RuboCop version 0.54.0.
|
|
# The point is for the user to remove these configuration records
|
|
# one by one as the offenses are removed from the code base.
|
|
# Note that changes in the inspected code, or installation of new
|
|
# versions of RuboCop, may require this file to be generated again.
|
|
|
|
# Offense count: 18
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: Include, TreatCommentsAsGroupSeparators.
|
|
# Include: **/*.gemfile, **/Gemfile, **/gems.rb
|
|
Bundler/OrderedGems:
|
|
Exclude:
|
|
- 'Gemfile'
|
|
- 'gemfiles/rails4.2.gemfile'
|
|
- 'gemfiles/rails5.0.gemfile'
|
|
- 'gemfiles/rails5.1.gemfile'
|
|
- 'gemfiles/rails5.2.gemfile'
|
|
|
|
# Offense count: 1
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: Include, TreatCommentsAsGroupSeparators.
|
|
# Include: **/*.gemspec
|
|
Gemspec/OrderedDependencies:
|
|
Exclude:
|
|
- 'factory_bot_rails.gemspec'
|
|
|
|
# Offense count: 4
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: EnforcedStyle.
|
|
# SupportedStyles: auto_detection, squiggly, active_support, powerpack, unindent
|
|
Layout/IndentHeredoc:
|
|
Exclude:
|
|
- 'features/step_definitions/rails_steps.rb'
|
|
- 'lib/generators/factory_bot/model/model_generator.rb'
|
|
|
|
# Offense count: 2
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: Width, IgnoredPatterns.
|
|
Layout/IndentationWidth:
|
|
Exclude:
|
|
- 'lib/generators/factory_bot/model/model_generator.rb'
|
|
|
|
# Offense count: 2
|
|
# Configuration parameters: CountComments, ExcludedMethods.
|
|
Metrics/BlockLength:
|
|
Max: 40
|
|
|
|
# Offense count: 1
|
|
Naming/MemoizedInstanceVariableName:
|
|
Exclude:
|
|
- 'lib/generators/factory_bot.rb'
|
|
|
|
# Offense count: 9
|
|
Style/Documentation:
|
|
Exclude:
|
|
- 'spec/**/*'
|
|
- 'test/**/*'
|
|
- 'lib/generators/factory_bot/model/model_generator.rb'
|
|
|
|
# Offense count: 29
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: EnforcedStyle, UseHashRocketsWithSymbolValues, PreferHashRocketsForNonAlnumEndingSymbols.
|
|
# SupportedStyles: ruby19, hash_rockets, no_mixed_keys, ruby19_no_mixed_keys
|
|
Style/HashSyntax:
|
|
Exclude:
|
|
- 'gemfiles/rails4.2.gemfile'
|
|
- 'gemfiles/rails5.0.gemfile'
|
|
- 'gemfiles/rails5.1.gemfile'
|
|
- 'gemfiles/rails5.2.gemfile'
|
|
|
|
# Offense count: 5
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: PreferredDelimiters.
|
|
Style/PercentLiteralDelimiters:
|
|
Exclude:
|
|
- 'factory_bot_rails.gemspec'
|
|
|
|
# Offense count: 84
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: EnforcedStyle, ConsistentQuotesInMultiline.
|
|
# SupportedStyles: single_quotes, double_quotes
|
|
Style/StringLiterals:
|
|
EnforcedStyle: "double_quotes"
|
|
Exclude:
|
|
- 'Gemfile'
|
|
- 'factory_bot_rails.gemspec'
|
|
- 'lib/generators/factory_bot.rb'
|
|
- 'lib/generators/factory_bot/model/model_generator.rb'
|
|
|
|
# Offense count: 1
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: EnforcedStyle.
|
|
# SupportedStyles: single_quotes, double_quotes
|
|
Style/StringLiteralsInInterpolation:
|
|
Exclude:
|
|
- 'lib/generators/factory_bot/model/model_generator.rb'
|
|
|
|
# Offense count: 4
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: EnforcedStyleForMultiline.
|
|
# SupportedStylesForMultiline: comma, consistent_comma, no_comma
|
|
Style/TrailingCommaInArguments:
|
|
Exclude:
|
|
- 'spec/factory_bot_rails/definition_file_paths_spec.rb'
|
|
- 'lib/generators/factory_bot/model/model_generator.rb'
|
|
|
|
# Offense count: 4
|
|
# Cop supports --auto-correct.
|
|
Style/UnneededPercentQ:
|
|
Exclude:
|
|
- 'factory_bot_rails.gemspec'
|
|
|
|
# Offense count: 2
|
|
# Cop supports --auto-correct.
|
|
# Configuration parameters: WordRegex.
|
|
# SupportedStyles: percent, brackets
|
|
Style/WordArray:
|
|
EnforcedStyle: percent
|
|
MinSize: 3
|
|
|
|
# Offense count: 11
|
|
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, IgnoredPatterns.
|
|
# URISchemes: http, https
|
|
Metrics/LineLength:
|
|
Max: 133
|