After a suggestion from my colleague Wietze, i decided to give fakemail a try. Fakemail will act as a mailserver, in that it accepts emails. It saves them to file, however. This eliminates the need for a real mailserver (be it on your local machine or via internet) during development.
To separate it from my default python installation, i create a virtualenv:
$ cd ~
$ virtualenv --no-site-packages venv_fakemail
$ . ./venv_fakemail/bin/activate
(venv_fakemail)$ cd /tmp
Go to http://sourceforge.net/projects/fakemail/files/fakemail-python/1.0beta/fakemail-python-1.0beta.tar.gz/download, save file in ~/Downloads/.
(venv_fakemail)$ tar -xzf ~/Downloads/fakemail-python-1.0beta.tar.gz
(venv_fakemail)$ cd fakemail-python-1.0beta/
(venv_fakemail)$ python setup.py install
$ ~/venv_fakemail/bin/fakemail.py --host=localhost --port=10025 --path=/tmp
Listening on port 10025
Now make your program (Plone site) connect to localhost:10025 and send mail:
Capturing mail to email@example.com
Mail to firstname.lastname@example.org saved
Incoming mail dispatched
The e-mail will be saved as /email@example.com.
easy_installing fakemail-python from pypi didn't work, although it's on pypi.
More info: http://www.lastcraft.com/fakemail.php