Send email from rails console
Quicker version:
ActionMailer::Base.mail(
from: "[email protected]",
to: "[email protected]",
subject: "Test",
body: "Test"
).deliver_now
I ran into a similar problem this morning on a Rails 3 app where I called:
UserMailer.activation_instructions(@user)
This gave me the data but did not send the e-mail out. To send, I called:
UserMailer.activation_instructions(@user).deliver
This did the trick. Hopefully this might work for you too!