Last active
December 19, 2018 02:52
-
-
Save namnv609/331b2eb8132467bea3a296351a1b9111 to your computer and use it in GitHub Desktop.
Test send email from Rails console
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class TestMailer < ApplicationMailer | |
def send_mail to | |
subject = "Test subject" | |
body = "Lorem ipsum dolor sit amet" | |
mail to: to, subject: subject, body: body | |
end | |
end | |
TestMailer.send_mail("[email protected]").deliver_now |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment