From b44247b4e513e4e99b82813048c1508a0ace9de3 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Sun, 1 Oct 2023 22:09:54 +0000 Subject: [PATCH 1/3] Bump rubocop-rspec from 2.23.2 to 2.24.1 Bumps [rubocop-rspec](https://github.com/rubocop/rubocop-rspec) from 2.23.2 to 2.24.1. - [Release notes](https://github.com/rubocop/rubocop-rspec/releases) - [Changelog](https://github.com/rubocop/rubocop-rspec/blob/master/CHANGELOG.md) - [Commits](https://github.com/rubocop/rubocop-rspec/compare/v2.23.2...v2.24.1) --- updated-dependencies: - dependency-name: rubocop-rspec dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- Gemfile | 2 +- Gemfile.lock | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Gemfile b/Gemfile index 897cdf8ff..afccd8d46 100644 --- a/Gemfile +++ b/Gemfile @@ -110,7 +110,7 @@ group :development do gem "rubocop-factory_bot", "~> 2.24.0", require: false gem "rubocop-performance", "~> 1.19.1", require: false gem "rubocop-rails", "~> 2.20.2", require: false - gem "rubocop-rspec", "~> 2.23.2", require: false + gem "rubocop-rspec", "~> 2.24.1", require: false gem "rvm1-capistrano3", "~> 1.4.0", require: false gem "scss_lint", "~> 0.60.0", require: false gem "web-console", "~> 4.2.1" diff --git a/Gemfile.lock b/Gemfile.lock index 141fb84e6..6e7688c2e 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -540,7 +540,7 @@ GEM activesupport (>= 4.2.0) rack (>= 1.1) rubocop (>= 1.33.0, < 2.0) - rubocop-rspec (2.23.2) + rubocop-rspec (2.24.1) rubocop (~> 1.33) rubocop-capybara (~> 2.17) rubocop-factory_bot (~> 2.22) @@ -755,7 +755,7 @@ DEPENDENCIES rubocop-factory_bot (~> 2.24.0) rubocop-performance (~> 1.19.1) rubocop-rails (~> 2.20.2) - rubocop-rspec (~> 2.23.2) + rubocop-rspec (~> 2.24.1) rvm1-capistrano3 (~> 1.4.0) sassc-rails (~> 2.1.2) savon (~> 2.14.0) From 013f3282e440842cab390a37127991f0f1c9f497 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Tue, 3 Oct 2023 20:30:52 +0200 Subject: [PATCH 2/3] Use the RSpec/FilePath rule replacements RSpec/FilePath is deprecated since rubocop-rspec 2.24.0 and will be removed in rubocop-rspec 3.0 in favor of RSpec/SpecFilePathFormat and RSpec/SpecFilePathSuffix. --- .rubocop.yml | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/.rubocop.yml b/.rubocop.yml index ac0daad61..a7714c1e7 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -547,9 +547,6 @@ RSpec/ExampleWording: RSpec/ExcessiveDocstringSpacing: Enabled: true -RSpec/FilePath: - Enabled: true - RSpec/Focus: Enabled: true @@ -603,6 +600,12 @@ RSpec/ScatteredLet: RSpec/ScatteredSetup: Enabled: true +RSpec/SpecFilePathFormat: + Enabled: true + +RSpec/SpecFilePathSuffix: + Enabled: true + RSpec/VoidExpect: Enabled: true From b59899e9f78c9ac63094866fbe9db224a285d889 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Javi=20Mart=C3=ADn?= Date: Tue, 3 Oct 2023 20:36:34 +0200 Subject: [PATCH 3/3] Add and apply RSpec/MetadataStyle rubocop rule This rule was introduced in rubocop-rspec 2.24.0. We were applying it most of the time. --- .rubocop.yml | 3 +++ spec/spec_helper.rb | 2 +- 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/.rubocop.yml b/.rubocop.yml index a7714c1e7..7d025999a 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -564,6 +564,9 @@ RSpec/LetBeforeExamples: RSpec/LetSetup: Enabled: true +RSpec/MetadataStyle: + Enabled: true + RSpec/NotToNot: Enabled: true diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index ffe0e3cfc..a82d425e6 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -63,7 +63,7 @@ RSpec.configure do |config| Capybara.default_set_options = { clear: :backspace } end - config.before(:each, type: :system, no_js: true) do + config.before(:each, :no_js, type: :system) do driven_by :rack_test Capybara.default_set_options = {} end