config/upstream.yml in cookstyle-7.12.6 vs config/upstream.yml in cookstyle-7.13.0

- old
+ new

@@ -1610,11 +1610,11 @@ Lint/EmptyBlock: Description: 'This cop checks for blocks without a body.' Enabled: pending VersionAdded: '1.1' - VersionChanged: '1.3' + VersionChanged: '1.15' AllowComments: true AllowEmptyLambdas: true Lint/EmptyClass: Description: 'Checks for classes and metaclasses without a body.' @@ -3478,10 +3478,11 @@ - braces - no_braces Style/HashConversion: Description: 'Avoid Hash[] in favor of ary.to_h or literal hashes.' + StyleGuide: '#avoid-hash-constructor' Enabled: pending VersionAdded: '1.10' VersionChanged: '1.11' AllowSplatArgument: true @@ -3996,10 +3997,11 @@ Style/NilLambda: Description: 'Prefer `-> {}` to `-> { nil }`.' Enabled: pending VersionAdded: '1.3' + VersionChanged: '1.15' Style/NonNilCheck: Description: 'Checks for redundant nil checks.' StyleGuide: '#no-non-nil-checks' Enabled: true @@ -4649,10 +4651,16 @@ - require_parentheses - require_no_parentheses - require_parentheses_when_complex AllowSafeAssignment: true +Style/TopLevelMethodDefinition: + Description: 'This cop looks for top-level method definitions.' + StyleGuide: '#top-level-methods' + Enabled: false + VersionAdded: '1.15' + Style/TrailingBodyOnClass: Description: 'Class body goes below class statement.' Enabled: true VersionAdded: '0.53' @@ -4735,11 +4743,11 @@ Style/TrivialAccessors: Description: 'Prefer attr_* methods to trivial readers/writers.' StyleGuide: '#attr_family' Enabled: true VersionAdded: '0.9' - VersionChanged: '0.77' + VersionChanged: '1.15' # When set to `false` the cop will suggest the use of accessor methods # in situations like: # # def name # @other_name @@ -4754,10 +4762,10 @@ # @on_exception=action # end # on_exception :restart # # Commonly used in DSLs - AllowDSLWriters: false + AllowDSLWriters: true IgnoreClassMethods: false AllowedMethods: - to_ary - to_a - to_c