Mercurial > babel > mirror
diff babel/messages/tests/pofile.py @ 105:c62b68a0b65e trunk
`Message`, `read_po` and `write_po` now all handle user/auto comments correctly.
The `Generated-By` header value needed a missing `\n`.
The frontends now pass the value of `--copyright-holder` to the Catalog, and removed the `copyright_holder` arg for `write_po` left behind on [105].
Tests changed accordingly.
author | palgarvio |
---|---|
date | Thu, 14 Jun 2007 06:24:28 +0000 |
parents | 395704fda00b |
children | 2cd83f77cc98 |
line wrap: on
line diff
--- a/babel/messages/tests/pofile.py +++ b/babel/messages/tests/pofile.py @@ -89,10 +89,10 @@ def test_pot_with_translator_comments(self): catalog = Catalog() catalog.add(u'foo', locations=[('main.py', 1)], - comments=['Comment About `foo`']) + auto_comments=['Comment About `foo`']) catalog.add(u'bar', locations=[('utils.py', 3)], - comments=['Comment About `bar` with', - 'multiple lines.']) + user_comments=['Comment About `bar` with', + 'multiple lines.']) buf = StringIO() pofile.write_po(buf, catalog, omit_header=True) self.assertEqual('''#. Comment About `foo` @@ -100,8 +100,8 @@ msgid "foo" msgstr "" -#. Comment About `bar` with -#. multiple lines. +# Comment About `bar` with +# multiple lines. #: utils.py:3 msgid "bar" msgstr ""''', buf.getvalue().strip())