I’ve noticed my Cucumber tests started to take a loooong time to run, and eventually I realized it’s because it’s trying to connect to an smtp server when I use mailers. I already have the following line on my test.rb file:
config.action_mailer.delivery_method = :test
However, that setting doesn’t seem to be followed. If I remove the line below from my mailer.rb file, then it all works fine:
ActionMailer::Base.delivery_method = :smtp
Of course if I remove that line, then the production version won’t work anymore…
Any ideas?
You probably have
Being set somewhere after the test.rb is run.
You should configure your production mailer details inside production.rb