From 8123121157b7fd2ec27ee1b9f7f6a23357955b4e Mon Sep 17 00:00:00 2001 From: Ken Grigsby Date: Fri, 19 Apr 2013 19:10:49 -0500 Subject: added methods to decode data as strings --- tests/test-all.mm | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) (limited to 'tests/test-all.mm') diff --git a/tests/test-all.mm b/tests/test-all.mm index 6107730e..73981e82 100644 --- a/tests/test-all.mm +++ b/tests/test-all.mm @@ -285,6 +285,14 @@ static void testAddresses() MCLog("%s", MCUTF8DESC(str)); } +static void testAttachments() +{ + mailcore::Attachment *attachment = mailcore::Attachment::attachmentWithText(MCSTR("Hello World")); + attachment->setCharset(NULL); + mailcore::String * str = attachment->decodedString(); + MCLog("%s", MCUTF8DESC(str)); +} + void testObjC() { MCOIMAPSession *session = [[MCOIMAPSession alloc] init]; @@ -341,8 +349,9 @@ void testAll() //testAsyncSMTP(data); //testAsyncIMAP(); //testAsyncPOP(); - testAddresses(); - //testObjC(); + //testAddresses(); + //testAttachments(); + testObjC(); MCLog("pool release"); pool->release(); -- cgit v1.2.3