This project is for testing various ActionMailer settings. Right now it's configured using ActionMailer 2.3.11, but it can easily be adapted to use other versions if necessary.
Clone the repository:
git clone https://github.com/watsonian/action_mailer_test.git
Make sure you have bundler installed:
gem install bundler
Switch directories to the cloned repo and bundle install:
cd action_mailer_test bundle install
Now edit the
action_mailer_test.rb file. You'll need to make sure you set the
FROM_ADDRESS constants and then adjust the smtp settings.
To actually test things out, you'll need to run the following command from your local clone:
bundle exec ruby action_mailer_test.rb
There will be no output if it's successful -- you'll know it works because you should receive an email at the
TO_ADDRESS you specified. If it fails for some reason, the error will be displayed.
Q: What settings do I need to use an SMTP server that doesn't require authentication?
A: Remove the
authentication keys from the smtp settings hash. That should work for you then assuming the other settings are correct.