Added integration test for mail communication