config/default.yml in rubocop-0.85.1 vs config/default.yml in rubocop-0.86.0

- old
+ new

@@ -1359,10 +1359,19 @@ Lint/CircularArgumentReference: Description: "Default values in optional keyword arguments and optional ordinal arguments should not refer back to the name of the argument." Enabled: true VersionAdded: '0.33' +Lint/ConstantResolution: + Description: 'Check that constants are fully qualified with `::`.' + Enabled: false + VersionAdded: '0.86' + # Restrict this cop to only looking at certain names + Only: [] + # Restrict this cop from only looking at certain names + Ignore: [] + Lint/Debugger: Description: 'Check for debugger calls.' Enabled: true VersionAdded: '0.14' VersionChanged: '0.49' @@ -1609,11 +1618,13 @@ Lint/RaiseException: Description: Checks for `raise` or `fail` statements which are raising `Exception` class. StyleGuide: '#raise-exception' Enabled: pending + Safe: false VersionAdded: '0.81' + VersionChanged: '0.86' AllowedImplicitNamespaces: - 'Gem' Lint/RandOne: Description: >- @@ -1666,10 +1677,11 @@ Description: >- Do not use regexp literal as a condition. The regexp literal matches `$_` implicitly. Enabled: true VersionAdded: '0.51' + VersionChanged: '0.86' Lint/RequireParentheses: Description: >- Use parentheses in the method call to avoid confusion about precedence. @@ -1923,11 +1935,11 @@ of test cases needed to validate a method. Enabled: true VersionAdded: '0.25' VersionChanged: '0.81' IgnoredMethods: [] - Max: 6 + Max: 7 Metrics/MethodLength: Description: 'Avoid methods longer than 10 lines of code.' StyleGuide: '#short-methods' Enabled: true @@ -3237,10 +3249,11 @@ Avoid multi-line ?: (the ternary operator); use if/unless instead. StyleGuide: '#no-multiline-ternary' Enabled: true VersionAdded: '0.9' + VersionChanged: '0.86' Style/MultilineWhenThen: Description: 'Do not use then for multi-line when statement.' StyleGuide: '#no-then' Enabled: true @@ -3341,10 +3354,11 @@ Style/NestedTernaryOperator: Description: 'Use one expression per branch in a ternary operator.' StyleGuide: '#no-nested-ternary' Enabled: true VersionAdded: '0.9' + VersionChanged: '0.86' Style/Next: Description: 'Use `next` to skip iteration instead of a condition at the end.' StyleGuide: '#no-nested-conditionals' Enabled: true @@ -3594,10 +3608,23 @@ StyleGuide: '#no-explicit-runtimeerror' Enabled: true VersionAdded: '0.14' VersionChanged: '0.29' +Style/RedundantFetchBlock: + Description: >- + Use `fetch(key, value)` instead of `fetch(key) { value }` + when value has Numeric, Rational, Complex, Symbol or String type, `false`, `true`, `nil` or is a constant. + Reference: 'https://github.com/JuanitoFatas/fast-ruby#hashfetch-with-argument-vs-hashfetch--block-code' + Enabled: 'pending' + Safe: false + # If enabled, this cop will autocorrect usages of + # `fetch` being called with block returning a constant. + # This can be dangerous since constants will not be defined at that moment. + SafeForConstants: false + VersionAdded: '0.86' + Style/RedundantFreeze: Description: "Checks usages of Object#freeze on immutable objects." Enabled: true VersionAdded: '0.34' VersionChanged: '0.66' @@ -3873,9 +3900,10 @@ Style/StructInheritance: Description: 'Checks for inheritance from Struct.new.' StyleGuide: '#no-extend-struct-new' Enabled: true VersionAdded: '0.29' + VersionChanged: '0.86' Style/SymbolArray: Description: 'Use %i or %I for arrays of symbols.' StyleGuide: '#percent-i' Enabled: true