From 9f702b085ba2fd9a7a64cd893f9bf8f5ff1af409 Mon Sep 17 00:00:00 2001 From: farhatahmad Date: Wed, 13 Dec 2023 14:27:51 -0500 Subject: [PATCH] Rubocop + Eslint + Rspec Clean up --- .eslintrc.yml | 1 + .rubocop.yml | 2 ++ Gemfile | 2 ++ Gemfile.lock | 12 ++++++++++++ spec/rails_helper.rb | 4 +++- 5 files changed, 20 insertions(+), 1 deletion(-) diff --git a/.eslintrc.yml b/.eslintrc.yml index 75658ad0c7..d678106efc 100644 --- a/.eslintrc.yml +++ b/.eslintrc.yml @@ -17,3 +17,4 @@ rules: max-len: - 'error' - code: 150 + jsx-a11y/control-has-associated-label: "off" diff --git a/.rubocop.yml b/.rubocop.yml index 1fed715036..0d83aabd6f 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -2,6 +2,8 @@ require: - rubocop-performance - rubocop-rails - rubocop-rspec + - rubocop-factory_bot + - rubocop-capybara AllCops: Exclude: diff --git a/Gemfile b/Gemfile index 7fa0c91099..1fe4b2481c 100644 --- a/Gemfile +++ b/Gemfile @@ -40,6 +40,8 @@ end group :development do gem 'rubocop', '~> 1.26', require: false + gem 'rubocop-capybara', '~> 2.19.0', require: false + gem 'rubocop-factory_bot', '~> 2.24.0', require: false gem 'rubocop-performance', '~> 1.13', require: false gem 'rubocop-rails', '~> 2.18', '>= 2.18.0', require: false gem 'rubocop-rspec', '~> 2.9.0', require: false diff --git a/Gemfile.lock b/Gemfile.lock index 3851b5bd66..fb218cf34f 100644 --- a/Gemfile.lock +++ b/Gemfile.lock @@ -409,6 +409,10 @@ GEM unicode-display_width (>= 2.4.0, < 3.0) rubocop-ast (1.29.0) parser (>= 3.2.1.0) + rubocop-capybara (2.19.0) + rubocop (~> 1.41) + rubocop-factory_bot (2.24.0) + rubocop (~> 1.33) rubocop-performance (1.16.0) rubocop (>= 1.7.0, < 2.0) rubocop-ast (>= 0.4.0) @@ -529,6 +533,8 @@ DEPENDENCIES remote_syslog_logger rspec-rails (>= 6.0.4) rubocop (~> 1.26) + rubocop-capybara (~> 2.19.0) + rubocop-factory_bot (~> 2.24.0) rubocop-performance (~> 1.13) rubocop-rails (~> 2.18, >= 2.18.0) rubocop-rspec (~> 2.9.0) @@ -539,3 +545,9 @@ DEPENDENCIES web-console (>= 4.2.1) webdrivers webmock + +RUBY VERSION + ruby 3.1.0p0 + +BUNDLED WITH + 2.3.9 diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index 99e401b016..f68b116b38 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -58,7 +58,9 @@ RSpec.configure do |config| # Remove this line if you're not using ActiveRecord or ActiveRecord fixtures - config.fixture_path = Rails.root.join('spec/fixtures"') + config.fixture_paths = [ + Rails.root.join('spec/fixtures') + ] # If you're not using ActiveRecord, or you'd prefer not to run each of your # examples within a transaction, remove the following line or assign false