diff --git a/.rubocop.yml b/.rubocop.yml index 147fbb070..137ef4cbb 100644 --- a/.rubocop.yml +++ b/.rubocop.yml @@ -269,8 +269,6 @@ Rails/HttpStatus: Rails/I18nLocaleAssignment: Enabled: true - Exclude: - - "spec/spec_helper.rb" Rails/InverseOf: Enabled: true diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index b8b155795..7e84626b4 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -30,11 +30,16 @@ RSpec.configure do |config| end config.before do |example| - I18n.locale = :en Globalize.set_fallbacks_to_all_available_locales Setting["feature.user.skip_verification"] = nil end + config.around do |example| + I18n.with_locale(:en) do + example.run + end + end + config.around(:each, :race_condition) do |example| self.use_transactional_tests = false example.run