Advertisement
YarikHrom

Untitled

May 25th, 2022
445
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. require: rubocop-rspec
  2.  
  3. # We are using default RuboCop settings.
  4. # We are writing beautiful code.
  5. # There is nothing to change here. At least now.
  6. AllCops:
  7.   TargetRubyVersion: 2.6
  8.   DisplayCopNames: true
  9.   ExtraDetails: true
  10.   Exclude:
  11.   # Ignore vendored gems
  12.   - vendor/**/*
  13.   - node_modules/**/*
  14.   - bin/**/*
  15.   - config/initializers/simple_form_bootstrap.rb
  16.   - 'db/migrate/*.rb'
  17.   - db/schema.rb
  18.   - db/seeds.rb
  19.   RSpec:
  20.     Patterns:
  21.     - '_spec.rb$'
  22.  
  23. # Ignore block length in DSLs using blocks extensively
  24. Metrics/BlockLength:
  25.   Exclude:
  26.   - config/routes.rb
  27.   # RSpec DSL
  28.   - '**/*_spec.rb'
  29.   - '**/spec/**/*.rb'
  30.   # Views
  31.   - 'app/views/**/*.rb'
  32.   # Config
  33.   - config/environments/development.rb
  34.   - config/environments/production.rb
  35.  
  36. Metrics/ClassLength:
  37.   Exclude:
  38.  
  39. Metrics/MethodLength:
  40.   Exclude:
  41.   # Rake DSL
  42.   - lib/rake/**.rb
  43.   - 'db/migrate/*.rb'
  44.   # RSpec DSL
  45.   - '**/spec/**/*.rb'
  46.  - 'app/views/**/*.rb'
  47.  
  48. Metrics/ModuleLength:
  49.  Exclude:
  50.  # RSpec DSL
  51.  - spec/**/*.rb
  52.  
  53. Metrics/AbcSize:
  54.  Exclude:
  55.  # RSpec DSL
  56.  - '**/spec/**/*.rb'
  57.  - 'app/views/**/*.rb'
  58.  
  59. Metrics/LineLength:
  60.  Max: 120
  61.  
  62. # Use UTF-8 as the source file encoding, specify when needed.
  63. Style/Encoding:
  64.  Enabled: true
  65.  
  66. Style/Alias:
  67.  EnforcedStyle: prefer_alias_method
  68.  
  69. Naming/MemoizedInstanceVariableName:
  70.  Enabled: false
  71.  
  72. Style/FormatStringToken:
  73.  EnforcedStyle: template
  74.  
  75. Style/MixinGrouping:
  76.  Exclude:
  77.  # RSpec DSL
  78.  - '**/spec/**/*.rb'
  79.  
  80. Style/MixinUsage:
  81.  Exclude:
  82.  # Rake DSL
  83.  - '**/rake/**/*.rb'
  84.  
  85. Style/IfUnlessModifier:
  86.  Enabled: false
  87.  
  88. Style/Documentation:
  89.  Enabled: false
  90.  
  91. Lint/AmbiguousBlockAssociation:
  92.  Enabled: false
  93.  
  94. Lint/Loop:
  95.  Enabled: false
  96.  
  97. # Rubocop Rspec rules
  98. RSpec/AnyInstance:
  99.  Enabled: false # Should be turned ON eventually
  100.  
  101. RSpec/ContextWording:
  102.  Enabled: false # Should be turned ON eventually
  103.  
  104. RSpec/DescribeClass:
  105.  Enabled: false
  106.  
  107. RSpec/EmptyExampleGroup:
  108.  Enabled: false # Should be turned ON eventually
  109.  
  110. RSpec/EmptyLineAfterFinalLet:
  111.  Enabled: true
  112.  
  113. RSpec/EmptyLineAfterSubject:
  114.  Enabled: true
  115.  
  116. RSpec/ExampleLength:
  117.  Enabled: false
  118.  
  119. RSpec/ExampleWording:
  120.  Enabled: true
  121.  
  122. RSpec/ExpectActual:
  123.  Enabled: true
  124.  
  125. RSpec/ExpectChange:
  126.  Enabled: true
  127.  EnforcedStyle: block
  128.  
  129. RSpec/ExpectOutput:
  130.  Enabled: true
  131.  
  132. RSpec/FilePath:
  133.  Enabled: true
  134.  
  135. RSpec/Focus:
  136.  Enabled: true
  137.  
  138. RSpec/HookArgument:
  139.  Enabled: true
  140.  
  141. RSpec/ImplicitSubject:
  142.  Enabled: false
  143.  
  144. RSpec/ImplicitExpect:
  145.  Enabled: true
  146.  
  147. RSpec/InstanceVariable:
  148.  Enabled: true
  149.  
  150. RSpec/LeadingSubject:
  151.  Enabled: true
  152.  
  153. RSpec/LetSetup:
  154.  Enabled: false
  155.  
  156. RSpec/MessageChain:
  157.  Enabled: false
  158.  
  159. RSpec/MessageExpectation:
  160.  Enabled: false
  161.  
  162. RSpec/MessageSpies:
  163.  Enabled: false
  164.  
  165. RSpec/MultipleDescribes:
  166.  Enabled: false
  167.  
  168. RSpec/MultipleExpectations:
  169.  Enabled: false
  170.  
  171. RSpec/NamedSubject:
  172.  Enabled: false
  173.  
  174. RSpec/NestedGroups:
  175.  Enabled: false
  176.  
  177. RSpec/NotToNot:
  178.  Enabled: false
  179.  
  180. RSpec/RepeatedDescription:
  181.  Enabled: true
  182.  
  183. RSpec/RepeatedExample:
  184.  Enabled: true
  185.  
  186. RSpec/ScatteredLet:
  187.  Enabled: false
  188.  
  189. RSpec/SingleArgumentMessageChain:
  190.  Enabled: true
  191.  
  192. RSpec/ScatteredSetup:
  193.  Enabled: false # Should be turned ON eventually
  194.  
  195. RSpec/SubjectStub:
  196.  Enabled: false
  197.  
  198. RSpec/VerifiedDoubles:
  199.  Enabled: false # Should be turned ON eventually
  200.  
  201. RSpec/MissingExampleGroupArgument:
  202.  Exclude:
  203.    - 'spec/factories/**/*'
Advertisement
RAW Paste Data Copied
Advertisement