def test_po2json_babel(po2json_babel, directory): po2json_babel.directory = directory po2json_babel.finalize_options() po2json_babel.run() for locale in os.listdir(directory): message_dir = os.path.join(directory, locale, 'LC_MESSAGES') po_file = os.path.join(message_dir, 'messages.po') check_po_to_json(po_file, message_dir)
def test_po2json_babel(po2json_babel, directory): po2json_babel.directory = directory po2json_babel.finalize_options() po2json_babel.run() for locale in os.listdir(directory): message_dir = os.path.join(directory, locale, 'LC_MESSAGES') po_file = os.path.join(message_dir, 'messages.po') check_po_to_json(po_file, message_dir)
def test_po2json_babel_without_input_files(po2json_babel): with raises(DistutilsOptionError): po2json_babel.finalize_options()
def test_po2json_babel_without_input_files(po2json_babel): with raises(DistutilsOptionError): po2json_babel.finalize_options()