Mercurial > p > roundup > code
view test/test_textfmt.py @ 4575:c426cb251bc7
Be more tolerant when parsing RFC2047 encoded mail headers.
Use backported version of my proposed changes to
email.header.decode_header in http://bugs.python.org/issue1079
| author | Ralf Schlatterbeck <rsc@runtux.com> |
|---|---|
| date | Wed, 04 Jan 2012 18:55:49 +0100 |
| parents | f35ece8f8ff7 |
| children | 364c54991861 |
line wrap: on
line source
import unittest from roundup.support import wrap class WrapTestCase(unittest.TestCase): def testWrap(self): lorem = '''Lorem ipsum dolor sit amet, consectetuer adipiscing elit.''' wrapped = '''Lorem ipsum dolor sit amet, consectetuer adipiscing elit.''' self.assertEquals(wrap(lorem, 20), wrapped) def test_suite(): suite = unittest.TestSuite() suite.addTest(unittest.makeSuite(WrapTestCase)) return suite
