view test/test_textfmt.py @ 4832:76460d14be91

Read version and release for generated documentation from roundup/__init__.py Release 1.5.0 contains documentation with version number 1.4, and the release number never included the third part.
author Thomas Arendsen Hein <thomas@intevation.de>
date Thu, 19 Sep 2013 16:23:42 +0200
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

Roundup Issue Tracker: http://roundup-tracker.org/