Added tests for mail sending