thermondo / pytest-translations

test translation files with pytest
Other
17 stars 3 forks source link

test for: is the MO up-to-date? #2

Closed syphar closed 9 years ago

syphar commented 9 years ago

this one is probably django-specific, since the discovery-settings in makemessages are.

syphar commented 9 years ago

we need either a local xgettext installation for this, or use a library like babel

codingjoe commented 9 years ago

you need xgettext anyway to use i18n

syphar commented 9 years ago

why?

codingjoe commented 9 years ago

well django needs xgettext to run compilemessages

syphar commented 9 years ago

Do check if the mo is up-to-date you don't need compilemessages.

It's about message discovery (makemessages) and the content of the mo

codingjoe commented 9 years ago

Chicken or the egg?

syphar commented 9 years ago

I don't understand ... ?

This issue is for catching the case that you marked strings for translation in your code, but didn't run makemessages.

What do you mean?

codingjoe commented 9 years ago

Ok, I though you wanted to actually compile the PO into an MO file.

What Is it you want to detect exactly? That the MO file is proper representation of PO or that it changed?

I feel, that this is over the top. We could rather extend our buildpack to compile all PO files.

syphar commented 9 years ago

currently we test (already):

So the only step not tested is:

syphar commented 9 years ago

but you'll see it if you finally review the plugin ;)

syphar commented 9 years ago

closing for now, is more nice-to have,