Add tests for library mailer (gh #35)