Skip to main content

Test your translation files

Project description

py.test plugin to test your translation files.


install via:

pip install pytest-translations

if you then type:

py.test --translations

every file ending in .mo and .po will be discovered and tested, starting from the command line arguments.

You also can execute only the translation-tests by using:

py.test -m translations --translations

This plugin uses polib to parse and test the catalogs.

Assertions on compiled .mo catalogs

  • there has to be a .po-file with the exact same name (only the different extension)

  • is has to be parseable

  • the .po file compiled again has to lead to the exact same entries

Assertions on plain .po catalogs

  • it has to be parseable

  • there mustn’t be any untranslated entries

  • there mustn’t be any fuzzy entries

  • there mustn’t be any obsolete entries


happens on

Project details

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytest-translations-0.2.0.tar.gz (3.2 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page