Add more email headers and some basic testing to the mailer