Skip to content
This repository has been archived by the owner on Mar 14, 2024. It is now read-only.

Commit

Permalink
Add interacts with mailables
Browse files Browse the repository at this point in the history
  • Loading branch information
MarkVaughn committed Nov 20, 2017
1 parent 4be92c2 commit 69a321a
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions tests/InteractsWithMailTest.php
Expand Up @@ -190,4 +190,20 @@ public function test_global_from()
$this->seeMessageFrom('me@example.com');
$this->seeMessageFrom('me@example.com', 'Example Person');
}

public function test_with_mailables()
{
$mailer = $this->mailer = $this->getMailThief();

$mailable = new TestMailable();
$mailable->to('john@example.com')
->from('me@example.com', 'Example Person')
->subject('Message for you');

$mailer->send($mailable);

$this->seeMessageFrom('me@example.com');
$this->seeMessageFrom('me@example.com', 'Example Person');
$this->seeInSubjects('Message for you');
}
}

1 comment on commit 69a321a

@mattstauffer
Copy link
Member

@mattstauffer mattstauffer commented on 69a321a Nov 20, 2017

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@MarkVaughn beautiful!

(Hadn't noticed you had added a second test--I'd still like to hear it's working fine in a real app, but love that coverage you just added)

Please sign in to comment.