From c53bf36b9a966d1a91fc8f9cb40dc1a9b4e73d95 Mon Sep 17 00:00:00 2001 From: Go MAEDA Date: Wed, 11 Jan 2023 13:25:07 +0000 Subject: [PATCH] Raise MinSize for RuboCop Performance/CollectionLiteralInLoop to 4 (#38146). git-svn-id: https://svn.redmine.org/redmine/trunk@22028 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- .rubocop.yml | 3 +++ .rubocop_todo.yml | 20 -------------------- 2 files changed, 3 insertions(+), 20 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index d411d2a9a..3baa592f2 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -116,6 +116,9 @@ Naming/BinaryOperatorParameterName: Naming/PredicateName: Enabled: false +Performance/CollectionLiteralInLoop: + MinSize: 4 + Rails/ActionControllerFlashBeforeRender: # False positive in actions where `redirect_to_referer_or` is used Enabled: false diff --git a/.rubocop_todo.yml b/.rubocop_todo.yml index 2576c467b..2ed0864d4 100644 --- a/.rubocop_todo.yml +++ b/.rubocop_todo.yml @@ -486,26 +486,6 @@ Naming/VariableNumber: - 'test/unit/lib/redmine/scm/adapters/mercurial_adapter_test.rb' - 'test/unit/project_test.rb' -# Configuration parameters: MinSize. -Performance/CollectionLiteralInLoop: - Exclude: - - 'app/helpers/imports_helper.rb' - - 'app/helpers/queries_helper.rb' - - 'app/helpers/settings_helper.rb' - - 'app/helpers/timelog_helper.rb' - - 'app/models/issue.rb' - - 'app/models/workflow_transition.rb' - - 'lib/redmine/helpers/time_report.rb' - - 'lib/redmine/scm/adapters/filesystem_adapter.rb' - - 'lib/redmine/wiki_formatting/textile/redcloth3.rb' - - 'test/functional/issues_custom_fields_visibility_test.rb' - - 'test/functional/repositories_git_controller_test.rb' - - 'test/functional/repositories_mercurial_controller_test.rb' - - 'test/functional/timelog_custom_fields_visibility_test.rb' - - 'test/unit/lib/redmine/scm/adapters/git_adapter_test.rb' - - 'test/unit/repository_git_test.rb' - - 'test/unit/repository_mercurial_test.rb' - # This cop supports safe autocorrection (--autocorrect). Performance/ConstantRegexp: Exclude: