Skip to content

Commit

Permalink
Merge pull request #279 from puppetlabs/CAT-1688-Upgrade_rubocop
Browse files Browse the repository at this point in the history
(CAT-1688) Upgrade rubocop to `~> 1.50.0`
  • Loading branch information
jordanbreen28 authored Jan 23, 2024
2 parents d9e902b + 81764ca commit c25251d
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 28 deletions.
3 changes: 3 additions & 0 deletions .rubocop.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,9 @@ AllCops:
Style/ClassAndModuleChildren:
Enabled: false

Layout/LineLength:
Max: 196

####################################################
# Cops below here due for deprecation
####################################################
Expand Down
34 changes: 7 additions & 27 deletions .rubocop_todo.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# This configuration was generated by
# `rubocop --auto-gen-config`
# on 2023-04-12 14:55:26 UTC using RuboCop version 1.50.1.
# on 2024-01-23 11:29:18 UTC using RuboCop version 1.50.2.
# 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
Expand All @@ -14,13 +14,6 @@ Gemspec/RequireMFA:
Exclude:
- 'ruby-pwsh.gemspec'

# Offense count: 1
# Configuration parameters: Severity, Include.
# Include: **/*.gemspec
Gemspec/RequiredRubyVersion:
Exclude:
- 'ruby-pwsh.gemspec'

# Offense count: 1
# Configuration parameters: IgnoreLiteralBranches, IgnoreConstantBranches.
Lint/DuplicateBranch:
Expand All @@ -38,11 +31,11 @@ Lint/EmptyClass:
Lint/IncompatibleIoSelectWithFiberScheduler:
Exclude:
- 'lib/pwsh.rb'
#

# Offense count: 17
# Configuration parameters: AllowedMethods, AllowedPatterns, CountRepeatedAttributes.
Metrics/AbcSize:
Max: 86
Max: 83

# Offense count: 2
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns, inherit_mode.
Expand All @@ -53,12 +46,12 @@ Metrics/BlockLength:
# Offense count: 2
# Configuration parameters: CountComments, CountAsOne.
Metrics/ClassLength:
Max: 529
Max: 526

# Offense count: 12
# Configuration parameters: AllowedMethods, AllowedPatterns.
Metrics/CyclomaticComplexity:
Max: 25
Max: 24

# Offense count: 22
# Configuration parameters: CountComments, CountAsOne, AllowedMethods, AllowedPatterns.
Expand All @@ -68,7 +61,7 @@ Metrics/MethodLength:
# Offense count: 10
# Configuration parameters: AllowedMethods, AllowedPatterns.
Metrics/PerceivedComplexity:
Max: 25
Max: 24

# Offense count: 1
# Configuration parameters: ExpectMatchingDefinition, CheckDefinitionPathHierarchy, CheckDefinitionPathHierarchyRoots, Regex, IgnoreExecutableScripts, AllowedAcronyms.
Expand Down Expand Up @@ -97,7 +90,7 @@ RSpec/BeforeAfterAll:
- 'spec/support/**/*.rb'
- 'spec/acceptance/dsc/basic.rb'

# Offense count: 81
# Offense count: 26
# Configuration parameters: Prefixes, AllowedPatterns.
# Prefixes: when, with, without
RSpec/ContextWording:
Expand All @@ -107,7 +100,6 @@ RSpec/ContextWording:
- 'spec/acceptance/dsc/class.rb'
- 'spec/acceptance/dsc/complex.rb'
- 'spec/unit/puppet/provider/dsc_base_provider/dsc_base_provider_spec.rb'
- 'spec/unit/pwsh/util_spec.rb'
- 'spec/unit/pwsh/windows_powershell_spec.rb'
- 'spec/unit/pwsh_spec.rb'

Expand Down Expand Up @@ -176,22 +168,10 @@ RSpec/SubjectStub:
Exclude:
- 'spec/unit/puppet/provider/dsc_base_provider/dsc_base_provider_spec.rb'

# Offense count: 6
Style/ClassVars:
Exclude:
- 'lib/puppet/provider/dsc_base_provider/dsc_base_provider.rb'

# Offense count: 1
# Configuration parameters: AllowedConstants.
Style/Documentation:
Exclude:
- 'spec/**/*'
- 'test/**/*'
- 'lib/puppet/provider/dsc_base_provider/dsc_base_provider.rb'

# Offense count: 121
# This cop supports safe autocorrection (--autocorrect).
# Configuration parameters: AllowHeredoc, AllowURI, URISchemes, IgnoreCopDirectives, AllowedPatterns.
# URISchemes: http, https
Layout/LineLength:
Max: 196
2 changes: 1 addition & 1 deletion Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@ group :development do
gem "parallel_tests", '= 3.12.1', require: false
gem "pry", '~> 0.10', require: false
gem "puppet-debugger", '~> 1.0', require: false
gem "rubocop", '= 1.48.1', require: false
gem "rubocop", '~> 1.50.0', require: false
gem "rubocop-performance", '= 1.16.0', require: false
gem "rubocop-rspec", '= 2.19.0', require: false
gem "puppet-strings", '~> 4.0', require: false
Expand Down

0 comments on commit c25251d

Please sign in to comment.