fix: align rubocop config between local CI and GitHub Actions (#11)

- Remove redundant Rails/Exit disable comments from spec/rails_helper.rb
- Add Rails/Exit exclusion for spec/ in .rubocop.yml
- Ensures both local (docker compose) and remote (GitHub Actions) agree

Co-authored-by: Sebastian Noe <sebastian.schneider@boxine.de>
pull/681/head
Sebastian Noe 1 month ago committed by GitHub
parent 93ac8b1d63
commit 3fe82a0f66
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

@ -116,6 +116,10 @@ Rails/StrongParametersExpect:
Rails/RedirectBackOrTo:
Enabled: false
Rails/Exit:
Exclude:
- spec/**/*
Rails/UnknownEnv:
Environments:
- development

@ -4,7 +4,7 @@ require 'spec_helper'
ENV['RAILS_ENV'] ||= 'test'
ENV['TZ'] ||= 'UTC'
require_relative '../config/environment'
abort('The Rails environment is running in production mode!') if Rails.env.production? # rubocop:disable Rails/Exit
abort('The Rails environment is running in production mode!') if Rails.env.production?
require 'rspec/rails'
require 'capybara/cuprite'
require 'capybara/rspec'
@ -42,7 +42,7 @@ Rails.root.glob('spec/support/**/*.rb').each { |f| require f }
begin
ActiveRecord::Migration.maintain_test_schema!
rescue ActiveRecord::PendingMigrationError => e
abort e.to_s.strip # rubocop:disable Rails/Exit
abort e.to_s.strip
end
RSpec.configure do |config|

Loading…
Cancel
Save