Spatie released a new package that we can use to send a mailable to an email-address in Laravel 5.

laravel mailable test

Do you have to fill out an entire form just to test a mail sent by your app? Or even worse, complete an entire checkout process to just view and debug an order confirmation mail? No more!

This package provides an artisan command that can send a mailable to an mail-address. It can be used like this:

php artisan mail:send-test "App\Mail\MyMailable" [email protected]

The given mailable will be sent to the given recipient. Any parameters the __construct method of the mailable class expect will be automagically passed in.