diff --git a/config/environments/production.rb b/config/environments/production.rb index bc17e3a..8efc2bc 100644 --- a/config/environments/production.rb +++ b/config/environments/production.rb @@ -117,7 +117,4 @@ Rails.application.configure do # Do not dump schema after migrations. config.active_record.dump_schema_after_migration = false - - # Middleware. - config.middleware.use Rack::Attack end diff --git a/config/environments/staging.rb b/config/environments/staging.rb index 734c10b..2fb844a 100644 --- a/config/environments/staging.rb +++ b/config/environments/staging.rb @@ -117,7 +117,4 @@ Rails.application.configure do # Do not dump schema after migrations. config.active_record.dump_schema_after_migration = false - - # Middleware. - config.middleware.use Rack::Attack end diff --git a/features/support/env.rb b/features/support/env.rb index 645924e..e225ccf 100644 --- a/features/support/env.rb +++ b/features/support/env.rb @@ -41,3 +41,5 @@ end # recommended as it will mask a lot of errors for you! # ActionController::Base.allow_rescue = false + +Rack::Attack.enabled = false diff --git a/spec/rails_helper.rb b/spec/rails_helper.rb index b06dc87..f503b82 100644 --- a/spec/rails_helper.rb +++ b/spec/rails_helper.rb @@ -51,6 +51,8 @@ end ActiveJob::Base.queue_adapter = :test +Rack::Attack.enabled = false + RSpec.configure do |config| # Remove this line if you're not using ActiveRecord or ActiveRecord fixtures config.fixture_path = Rails.root.join('fixtures').to_s