From 7a3c3bbc2d42ed7f09333d72485fade3381550a1 Mon Sep 17 00:00:00 2001 From: Klaus Zanders Date: Tue, 5 Sep 2023 13:40:39 +0200 Subject: [PATCH] Add rubocop-performance --- .rubocop.yml | 1 + Gemfile | 1 + Gemfile.lock | 4 ++++ 3 files changed, 6 insertions(+) diff --git a/.rubocop.yml b/.rubocop.yml index be7279bbbdc..1800b351ff3 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -5,6 +5,7 @@ require: - ./lib_static/rubocop/cop/open_project/use_service_result_factory_methods.rb - rubocop-capybara - rubocop-factory_bot + - rubocop-performance <% if File.exist?('.rubocop-local.yml') %> inherit_from: diff --git a/Gemfile b/Gemfile index 35a4543de49..c8b7cee1c8b 100644 --- a/Gemfile +++ b/Gemfile @@ -308,6 +308,7 @@ group :development, :test do gem 'rubocop', require: false gem 'rubocop-rails', require: false gem 'rubocop-rspec', require: false + gem 'rubocop-performance', require: false # Brakeman scanner gem 'brakeman', '~> 6.0.0' diff --git a/Gemfile.lock b/Gemfile.lock index 1eb1ac2697d..e894165f698 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -858,6 +858,9 @@ GEM rubocop (~> 1.41) rubocop-factory_bot (2.23.1) rubocop (~> 1.33) + rubocop-performance (1.19.0) + rubocop (>= 1.7.0, < 2.0) + rubocop-ast (>= 0.4.0) rubocop-rails (2.20.2) activesupport (>= 4.2.0) rack (>= 1.1) @@ -1135,6 +1138,7 @@ DEPENDENCIES rspec-rails (~> 6.0.0) rspec-retry (~> 0.6.1) rubocop + rubocop-performance rubocop-rails rubocop-rspec ruby-duration (~> 3.2.0)