Mercurial > p > roundup > code
view test/test_textfmt.py @ 4838:6102252d3a8a
Do not throw an internal error if a .mo file can not be read
It is better to fall back to English (as already done in other situations)
than causing an internal server error.
| author | Thomas Arendsen Hein <thomas@intevation.de> |
|---|---|
| date | Wed, 02 Oct 2013 15:36:34 +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
