Add unit test for email