concept fakemail in category php

This is an excerpt from Manning's book PHP in Action: Objects, Design, Agility.
In this section, we’ll see how to install fakemail, devise a test with it, and implement the Mailer class accordingly. Then we’ll discuss how the implementation is actually an Adapter on a Zend framework class.
So how do we create a fake mail server? As it happens, one of the authors was faced with exactly this task while working on a recent project. The resulting spin-off was the fakemail project on Sourceforge (http://sf.net/projects/fakemail/). Rather than write our own stub, we’ll use this one.
Starting fakemail Listening on port 25
We now send a mail as we normally would, as shown in figure 10.7. We then find that fakemail has captured it into a file called someone@somewhere.com.1. If we were to send another mail to the same address, it would be saved as someone@somewhere.com.2. We stop fakemail by hitting Ctrl-C in the terminal. The captured mail should look something like this: