diff options
author | Yves Senn <yves.senn@gmail.com> | 2015-08-28 09:56:33 +0200 |
---|---|---|
committer | Yves Senn <yves.senn@gmail.com> | 2015-08-28 09:56:33 +0200 |
commit | 9e2b13ca35656b6604fc28cd02f01f332ae19691 (patch) | |
tree | 6e7d8d928730dae8d2b0a45e578b87b13e861518 /guides | |
parent | 93a4dfaebc48e3324997be780539fad996349c84 (diff) | |
parent | 7ddf72d008ed35562401034e78e589b138c3041a (diff) | |
download | rails-9e2b13ca35656b6604fc28cd02f01f332ae19691.tar.gz rails-9e2b13ca35656b6604fc28cd02f01f332ae19691.tar.bz2 rails-9e2b13ca35656b6604fc28cd02f01f332ae19691.zip |
Merge pull request #21417 from rousisk/docfix
fix reference to undefined variable in email testing guide [ci skip]
Diffstat (limited to 'guides')
-rw-r--r-- | guides/source/testing.md | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/guides/source/testing.md b/guides/source/testing.md index 1cc49a36d2..aa3497fa13 100644 --- a/guides/source/testing.md +++ b/guides/source/testing.md @@ -1115,10 +1115,13 @@ require 'test_helper' class UserMailerTest < ActionMailer::TestCase test "invite" do + # Create the email and store it for further assertions + email = UserMailer.create_invite('me@example.com', + 'friend@example.com', Time.now) + # Send the email, then test that it got queued assert_emails 1 do - email = UserMailer.create_invite('me@example.com', - 'friend@example.com', Time.now).deliver_now + email.deliver_now end # Test the body of the sent email contains what we expect it to |