anaconda/anaconda-40.22.3.13/tests/gettext_tests/canary_tests.sh

20 lines
557 B
Bash
Raw Normal View History

2024-11-14 21:39:56 -08:00
#!/bin/sh -e
# Run the translation-canary tests on translatable strings.
# If not run from automake, fake it
if [ -z "$top_srcdir" ]; then
top_srcdir="$(dirname "$0")/../.."
fi
. "${top_srcdir}/tests/testenv.sh"
# Make sure anaconda.pot is update to date
# shellcheck disable=SC2154
make -C "${top_builddir}/po" anaconda.pot-update >/dev/null 2>&1
PYTHONPATH="${PYTHONPATH}:${top_srcdir}/translation-canary"
export PYTHONPATH
# Run the translatable tests on the POT file
python3 -m translation_canary.translatable "${top_builddir}/po/anaconda.pot"