diff --git a/core/app/models/spree/log_entry.rb b/core/app/models/spree/log_entry.rb index 20797f02165..25568952e2f 100644 --- a/core/app/models/spree/log_entry.rb +++ b/core/app/models/spree/log_entry.rb @@ -4,7 +4,7 @@ class LogEntry < Spree::Base # Fix for https://github.com/spree/spree/issues/1767 # If a payment fails, we want to make sure we keep the record of it failing - after_rollback :save_anyway + after_rollback :save_anyway, if: proc { !Rails.env.test? } def save_anyway log = Spree::LogEntry.new