Added tests for attachments