diff options
author | Ryan Johnson <ryan@iambismark.net> | 2013-07-11 18:45:04 -0500 |
---|---|---|
committer | Ryan Johnson <ryan@iambismark.net> | 2013-07-11 18:45:04 -0500 |
commit | 6594f1527f9392ed74201d726b0c6aa6897e372b (patch) | |
tree | 06ca5c249d8888508f15a4b08f7bd3efc95bc8a4 /tests | |
parent | 31762d8a7434268f08ae7dfbf06edc95754efb25 (diff) |
Adds NULL check and style cleanup
* Adds check for mExtraHeaders == NULL to all allExtraHeadersNames()
* Makes mExtraHeaders == NULL checks more consistent
* Cleans up code formatting to be more consistent
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test-all.mm | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/test-all.mm b/tests/test-all.mm index d4b00762..88eeabf1 100644 --- a/tests/test-all.mm +++ b/tests/test-all.mm @@ -53,9 +53,10 @@ static mailcore::Data * testMessageBuilder() bcc->addObject(mailcore::Address::addressWithDisplayName(MCSTR("Hidden Recipient"), MCSTR("foobar@bcc-recipient.org"))); msg->header()->setTo(to); msg->header()->setBcc(bcc); - msg->header()->addHeader(MCSTR("X-Custom-Header"), MCSTR("Custom Header Value")); to->release(); bcc->release(); + MCAssert(msg->header()->allExtraHeadersNames()->count() == 0); + msg->header()->addHeader(MCSTR("X-Custom-Header"), MCSTR("Custom Header Value")); msg->header()->setSubject(MCSTR("Mon projet d'été")); msg->setHTMLBody(MCSTR("<div>Hello <img src=\"cid:1234\"></div>")); msg->addAttachment(mailcore::Attachment::attachmentWithContentsOfFile(MCSTR("first-filename"))); |