If you ever needed to test something mail based on your local computer you may know the pain of waiting for the mail to be processed by your local smtp server and then delivered to your inbox, which probably just marked your test mail as spam.
Well fear no more, because I found a solution to your problem!
Mailcatcher is a simple smtp server which catches all mails that are sent and displays them in a web interface.
You can install it via rubygem with this command.
gem install mailcatcher
You can then launch the server with the command.
To configure for example your local php installation to only send mail to this server you have to set the value of the php configuration sendmail_path to the following value.
sendmail_path = /usr/bin/env catchmail -f firstname.lastname@example.org
Restart your webserver and you can use the normal mail function to send a mail and it will be displayed on the web interface on http://localhost:1080/