def test_mark_message_lines(): # e - empty line # s - splitter line # m - line starting with quotation marker '>' # t - the rest lines = [ 'Hello', '', # next line should be marked as splitter '_____________', 'From: [email protected]', 'Date: Wed, 16 May 2012 00:15:02 -0600', '', '> Hi', '', 'Signature' ] eq_('tesssemet', quotations.mark_message_lines(lines)) lines = [ 'Just testing the email reply', '', 'Robert J Samson', 'Sent from my iPhone', '', # all 3 next lines should be marked as splitters 'On Nov 30, 2011, at 12:47 PM, Skapture <', ('416ffd3258d4d2fa4c85cfa4c44e1721d66e3e8f4' '@skapture-staging.mailgun.org>'), 'wrote:', '', 'Tarmo Lehtpuu has posted the following message on' ] eq_('tettessset', quotations.mark_message_lines(lines))
def test_mark_message_lines(): # e - empty line # s - splitter line # m - line starting with quotation marker '>' # t - the rest lines = ['Hello', '', # next line should be marked as splitter '_____________', 'From: [email protected]', '', '> Hi', '', 'Signature'] eq_('tessemet', quotations.mark_message_lines(lines)) lines = ['Just testing the email reply', '', 'Robert J Samson', 'Sent from my iPhone', '', # all 3 next lines should be marked as splitters 'On Nov 30, 2011, at 12:47 PM, Skapture <', ('416ffd3258d4d2fa4c85cfa4c44e1721d66e3e8f4' '@skapture-staging.mailgun.org>'), 'wrote:', '', 'Tarmo Lehtpuu has posted the following message on'] eq_('tettessset', quotations.mark_message_lines(lines))
def test_mark_message_lines(): # e - empty line # s - splitter line # m - line starting with quotation marker '>' # t - the rest lines = [ "Hello", "", # next line should be marked as splitter "_____________", "From: [email protected]", "Date: Wed, 16 May 2012 00:15:02 -0600", "", "> Hi", "", "Signature", ] eq_("tesssemet", quotations.mark_message_lines(lines)) lines = [ "Just testing the email reply", "", "Robert J Samson", "Sent from my iPhone", "", # all 3 next lines should be marked as splitters "On Nov 30, 2011, at 12:47 PM, Skapture <", "416ffd3258d4d2fa4c85cfa4c44e1721d66e3e8f4" "@skapture-staging.mailgun.org>", "wrote:", "", "Tarmo Lehtpuu has posted the following message on", ] eq_("tettessset", quotations.mark_message_lines(lines))