From aa4377a8f152a961f139e19b92af415a9871f016 Mon Sep 17 00:00:00 2001 From: Maxim Krizhanovski Date: Wed, 30 Mar 2022 16:05:38 +0100 Subject: [PATCH] Remove obsolete AllowComments option --- config/default.yml | 2 +- spec/rubocop/cop/lint/useless_method_definition_spec.rb | 2 -- 2 files changed, 1 insertion(+), 3 deletions(-) diff --git a/config/default.yml b/config/default.yml index a259887819f..6f00f110e80 100644 --- a/config/default.yml +++ b/config/default.yml @@ -2327,8 +2327,8 @@ Lint/UselessMethodDefinition: Description: 'Checks for useless method definitions.' Enabled: true VersionAdded: '0.90' + VersionChanged: '0.91' Safe: false - AllowComments: true Lint/UselessRuby2Keywords: Description: 'Finds unnecessary uses of `ruby2_keywords`.' diff --git a/spec/rubocop/cop/lint/useless_method_definition_spec.rb b/spec/rubocop/cop/lint/useless_method_definition_spec.rb index f1ba8a2c94d..ed0fa56c8d6 100644 --- a/spec/rubocop/cop/lint/useless_method_definition_spec.rb +++ b/spec/rubocop/cop/lint/useless_method_definition_spec.rb @@ -1,8 +1,6 @@ # frozen_string_literal: true RSpec.describe RuboCop::Cop::Lint::UselessMethodDefinition, :config do - let(:cop_config) { { 'AllowComments' => true } } - it 'does not register an offense for empty constructor' do expect_no_offenses(<<~RUBY) class Foo