]> git.openstreetmap.org Git - rails.git/blobdiff - config/environments/test.rb
Disable logging in tests for speed benefits?
[rails.git] / config / environments / test.rb
index 08d3236bfd21dc6a328d8acdbf9320f1053b7273..506ccf6433519cba3ba79a173e26a0985dc28b15 100644 (file)
@@ -11,6 +11,9 @@ Rails.application.configure do
   # While tests run files are not watched, reloading is not necessary.
   config.enable_reloading = false
 
+  # disable logging in tests, for speed increases. Set to :info to bring back logging
+  config.log_level = :warn
+
   # Eager loading loads your entire application. When running a single test locally,
   # this is usually not necessary, and can slow down your test suite. However, it's
   # recommended that you enable it in continuous integration systems to ensure eager
@@ -67,4 +70,7 @@ Rails.application.configure do
 
   # Use the test adapter for ActiveJob during testing.
   config.active_job.queue_adapter = :test
+
+  # Allow FactoryBot to set primary key attributes
+  config.factory_bot.reject_primary_key_attributes = false
 end