def test_first_line_is_continuation_header(self):
eq = self.assertEqual
m = ' Line 1\nLine 2\nLine 3'
msg = email.message_from_string(m)
eq(msg.keys(), [])
eq(msg.get_payload(), 'Line 2\nLine 3')
eq(len(msg.defects), 1)
self.assertIsInstance(msg.defects[0],
errors.FirstHeaderLineIsContinuationDefect)
eq(msg.defects[0].line, ' Line 1\n')
# Test RFC 2047 header encoding and decoding
评论列表
文章目录