def test_generate_pots(self):
     # Generate all PO templates in the package.
     self.prepare_package("intltool_full_ok")
     expected_paths = [
         './po-module1/packagename-module1.pot',
         './po-module2/packagename-module2.pot',
         ]
     pots_list = generate_pots()
     self.assertEqual(expected_paths, pots_list)
     for expected_path in expected_paths:
         self.assertTrue(
             os.access(expected_path, os.F_OK),
             "Generated PO template '%s' not found." % expected_path)
Beispiel #2
0
 def test_generate_pots(self):
     # Generate all PO templates in the package.
     self.prepare_package("intltool_full_ok")
     expected_paths = [
         './po-module1/packagename-module1.pot',
         './po-module2/packagename-module2.pot',
     ]
     pots_list = generate_pots()
     self.assertEqual(expected_paths, pots_list)
     for expected_path in expected_paths:
         self.assertTrue(
             os.access(expected_path, os.F_OK),
             "Generated PO template '%s' not found." % expected_path)
#!/usr/bin/python -S
#
# Copyright 2009 Canonical Ltd.  This software is licensed under the
# GNU Affero General Public License version 3 (see the file LICENSE).

"""Print a list of directories that contain a valid intltool structure."""

import _pythonpath

from lpbuildd.pottery.intltool import generate_pots


if __name__ == "__main__":
    print "\n".join(generate_pots())