From 1e312dfa41dae776c7dec73fac9acc161073454a Mon Sep 17 00:00:00 2001 From: Maikel Linke Date: Thu, 15 Nov 2018 14:30:46 +1100 Subject: [PATCH] Update test mail setup for Spree 2 https://github.com/openfoodfoundation/openfoodnetwork/issues/2882 The email setup differs between Spree 1 and Spree 2. We already encapsulated that setup in a single method which now needed changing. --- spec/support/email_helper.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/spec/support/email_helper.rb b/spec/support/email_helper.rb index 7ba3c19f1c..aea0cee76d 100644 --- a/spec/support/email_helper.rb +++ b/spec/support/email_helper.rb @@ -5,7 +5,7 @@ module OpenFoodNetwork # It's here in a single place to allow an easy upgrade to Spree 2 which # needs a different implementation of this method. def setup_email - create(:mail_method) + Spree::Config[:mails_from] = "test@ofn.example.org" end end end