better test the class with an acceptance test and a mail test
inject a function to actually send the mail (I leave it up to you)