-
-
Notifications
You must be signed in to change notification settings - Fork 725
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Ensure perform_deliveries is correctly set when testing user confirma…
…tion emails
- Loading branch information
1 parent
8dfdc9b
commit e27f7a4
Showing
1 changed file
with
5 additions
and
3 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -76,9 +76,11 @@ | |
it "should send a confirmation email" do | ||
setup_email | ||
|
||
expect do | ||
create(:user, email: '[email protected]', confirmation_sent_at: nil, confirmed_at: nil) | ||
end.to send_confirmation_instructions | ||
performing_deliveries do | ||
expect do | ||
create(:user, email: '[email protected]', confirmation_sent_at: nil, confirmed_at: nil) | ||
end.to send_confirmation_instructions | ||
end | ||
|
||
sent_mail = ActionMailer::Base.deliveries.last | ||
expect(sent_mail.to).to eq ['[email protected]'] | ||
|