1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
|
#!/bin/sh
#
# Test with a correct ISO-8859-1 (Latin1) German text.
#
# (c) 2018 Roland Rosenfeld <roland@debian.org>
TESTSDIR=$(dirname $0)
if [ -z "$AUTOPKGTEST_TMP" ]; then
AUTOPKGTEST_TMP=$(mktemp -d)
fi
trap "rm -rf $AUTOPKGTEST_TMP" EXIT
iconv -f UTF-8 -t ISO-8859-1 < $TESTSDIR/correct.utf8.txt \
> $AUTOPKGTEST_TMP/correct.latin1.txt
OUTPUT=$(ispell -l -w '' -Tlatin1 -C -d ngerman \
< $AUTOPKGTEST_TMP/correct.latin1.txt)
if [ -z "$OUTPUT" ]
then
exit 0
else
echo "ispell did not accept the following words:"
echo $OUTPUT
exit 1
fi
|