+2002-01-08 Bruno Haible <bruno@clisp.org>
+
+ * msgattrib-*: Terminate the test immediately if the msg* program
+ fails.
+ * msgcat-*: Likewise.
+ * msgcomm-*: Likewise.
+ * msgconv-*: Likewise.
+ * msgen-*: Likewise.
+ * msgexec-*: Likewise.
+ * msgfilter-*: Likewise.
+ * msgfmt-*: Likewise.
+ * msggrep-*: Likewise.
+ * msgmerge-*: Likewise.
+ * msgunfmt-*: Likewise.
+ * msguniq-*: Likewise.
+ * xgettext-*: Likewise.
+
2002-01-08 Bruno Haible <bruno@clisp.org>
* format-elisp-1: New file.
tmpfiles="$tmpfiles ma-test1.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --translated ma-test1.po -o ma-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test1.ok"
cat <<EOF > ma-test1.ok
tmpfiles="$tmpfiles ma-test10.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --set-obsolete ma-test10.po -o ma-test10.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test10.ok"
cat <<EOF > ma-test10.ok
tmpfiles="$tmpfiles ma-test11.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --clear-obsolete ma-test11.po -o ma-test11.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test11.ok"
cat <<EOF > ma-test11.ok
tmpfiles="$tmpfiles ma-test12.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --fuzzy ma-test12.po -o ma-test12.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test12.ok"
cat <<EOF > ma-test12.ok
tmpfiles="$tmpfiles ma-test13.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --obsolete ma-test13.po -o ma-test13.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test13.ok"
cat <<EOF > ma-test13.ok
tmpfiles="$tmpfiles ma-test14.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --obsolete --no-fuzzy ma-test14.po -o ma-test14.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test14.ok"
cat <<EOF > ma-test14.ok
tmpfiles="$tmpfiles ma-test2.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --untranslated ma-test2.po -o ma-test2.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test2.ok"
cat <<EOF > ma-test2.ok
tmpfiles="$tmpfiles ma-test3.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --no-fuzzy ma-test3.po -o ma-test3.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test3.ok"
cat <<EOF > ma-test3.ok
tmpfiles="$tmpfiles ma-test4.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --only-fuzzy ma-test4.po -o ma-test4.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test4.ok"
cat <<EOF > ma-test4.ok
tmpfiles="$tmpfiles ma-test5.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --no-obsolete ma-test5.po -o ma-test5.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test5.ok"
cat <<EOF > ma-test5.ok
tmpfiles="$tmpfiles ma-test6.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --only-obsolete ma-test6.po -o ma-test6.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test6.ok"
cat <<EOF > ma-test6.ok
tmpfiles="$tmpfiles ma-test7.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --translated --only-obsolete ma-test7.po -o ma-test7.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test7.ok"
cat <<EOF > ma-test7.ok
tmpfiles="$tmpfiles ma-test8.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --set-fuzzy ma-test8.po -o ma-test8.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test8.ok"
cat <<EOF > ma-test8.ok
tmpfiles="$tmpfiles ma-test9.out"
: ${MSGATTRIB=msgattrib}
${MSGATTRIB} --clear-fuzzy ma-test9.po -o ma-test9.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles ma-test9.ok"
cat <<EOF > ma-test9.ok
tmpfiles="$tmpfiles mcat-test1.out"
: ${MSGCAT=msgcat}
${MSGCAT} mcat-test1.in1 mcat-test1.in2 -o mcat-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test1.ok"
cat << EOF > mcat-test1.ok
msgstr "Sie können sich als \"%1\" einloggen."
EOF
-tmpfiles="$tmpfiles mcat-test2.out"
+tmpfiles="$tmpfiles mcat-test2.out mcat-test2.err"
rm -f mcat-test2.out
: ${MSGCAT=msgcat}
LC_MESSAGES=C LC_ALL= \
${MSGCAT} --more-than=0 -o mcat-test2.out \
- mcat-test2.in1 mcat-test2.in2 2>&1 \
- | grep -v 'warning: .* encodings' | grep -v '^ '
+ mcat-test2.in1 mcat-test2.in2 >mcat-test2.err 2>&1
+result=$?
+cat mcat-test2.err | grep -v 'warning: .* encodings' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test2.ok"
cat << \EOF > mcat-test2.ok
msgstr "Sie können sich als \"%1\" einloggen."
EOF
-tmpfiles="$tmpfiles mcat-test3.out"
+tmpfiles="$tmpfiles mcat-test3.out mcat-test3.err"
rm -f mcat-test3.out
: ${MSGCAT=msgcat}
LC_MESSAGES=C LC_ALL= \
${MSGCAT} --use-first --more-than=0 -o mcat-test3.out \
- mcat-test3.in1 mcat-test3.in2 2>&1 \
- | grep -v 'warning: .* encodings' | grep -v '^ '
+ mcat-test3.in1 mcat-test3.in2 >mcat-test3.err 2>&1
+result=$?
+cat mcat-test3.err | grep -v 'warning: .* encodings' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test3.ok"
cat << \EOF > mcat-test3.ok
"Glückwunsch!"
EOF
-tmpfiles="$tmpfiles mcat-test4.out"
+tmpfiles="$tmpfiles mcat-test4.out mcat-test4.err"
rm -f mcat-test4.out
: ${MSGCAT=msgcat}
LC_MESSAGES=C LC_ALL= \
${MSGCAT} --use-first --more-than=0 -o mcat-test4.out \
- mcat-test4.in1 mcat-test4.in2 2>&1 \
- | grep -v 'warning: .* encodings' | grep -v '^ '
+ mcat-test4.in1 mcat-test4.in2 >mcat-test4.err 2>&1
+result=$?
+cat mcat-test4.err | grep -v 'warning: .* encodings' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test4.ok"
cat << \EOF > mcat-test4.ok
: ${MSGCAT=msgcat}
${MSGCAT} --use-first --more-than=0 -o mcat-test5.out \
mcat-test5.in1 mcat-test5.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test5.ok"
cat << EOF > mcat-test5.ok
: ${MSGCAT=msgcat}
${MSGCAT} --more-than=0 -o mcat-test6.out \
mcat-test6.in1 mcat-test6.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test6.ok"
cat << EOF > mcat-test6.ok
rm -f mcat-test7.out
: ${MSGCAT=msgcat}
${MSGCAT} mcat-test7.in1 --sort-output -o mcat-test7.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcat-test7.ok"
cat << EOF > mcat-test7.ok
tmpfiles="$tmpfiles mcomm-test1.out"
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 -o mcomm-test1.out mcomm-test1.in1 mcomm-test1.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test1.ok"
cat << EOF > mcomm-test1.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=1 --no-location --omit-header -o mcomm-test10.out \
mcomm-test10.in1 mcomm-test10.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test10.ok"
cat << EOF > mcomm-test10.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=1 --no-location --omit-header -o mcomm-test11.out \
mcomm-test11.in1 mcomm-test11.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test11.ok"
cat << EOF > mcomm-test11.ok
# switches? Are 'for' loops allowed? -ke-
${MSGCOMM} --less-than=2 --no-location --force-po -o mcomm-test12.out \
mcomm-test12.in1 mcomm-test12.in2 mcomm-test12.in3
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test12.ok"
cat << EOF > mcomm-test12.ok
# switches? Are 'for' loops allowed? -ke-
${MSGCOMM} --less-than=2 --no-location --force-po -o mcomm-test13.out \
mcomm-test13.in1 mcomm-test13.in2 mcomm-test13.in3
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test13.ok"
cat << EOF > mcomm-test13.ok
# switches? Are 'for' loops allowed? -ke-
${MSGCOMM} --less-than=2 --no-location --force-po -o mcomm-test14.out \
mcomm-test14.in1 mcomm-test14.in2 mcomm-test14.in3
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test14.ok"
cat << EOF > mcomm-test14.ok
# switches? Are 'for' loops allowed? -ke-
${MSGCOMM} --less-than=2 --no-location -o mcomm-test15.out \
mcomm-test15.in1 mcomm-test15.in2 mcomm-test15.in3
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
# we've no unique msg; thus no PO should be created.
if test -f mcomm-test15.out; then
msgstr "Sie können sich als \"%1\" einloggen."
EOF
-tmpfiles="$tmpfiles mcomm-test16.out"
+tmpfiles="$tmpfiles mcomm-test16.out mcomm-test16.err"
rm -f mcomm-test16.out
: ${MSGCOMM=msgcomm}
LC_MESSAGES=C LC_ALL= \
${MSGCOMM} --more-than=0 -o mcomm-test16.out \
- mcomm-test16.in1 mcomm-test16.in2 2>&1 \
- | grep -v 'warning: .* encodings' | grep -v '^ '
+ mcomm-test16.in1 mcomm-test16.in2 >mcomm-test16.err 2>&1
+result=$?
+cat mcomm-test16.err | grep -v 'warning: .* encodings' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test16.ok"
cat << \EOF > mcomm-test16.ok
${MSGCOMM} -u mcomm-test17.in1 mcomm-test17.in2 mcomm-test17.in3 \
-o mcomm-test17.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test17.ok"
cat << EOF > mcomm-test17.ok
tmpfiles="$tmpfiles mcomm-test18.out"
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 mcomm-test18.in1 mcomm-test18.in2 -o mcomm-test18.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test18.ok"
cat << EOF > mcomm-test18.ok
tmpfiles="$tmpfiles mcomm-test19.out"
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 mcomm-test19.in1 mcomm-test19.in2 -o mcomm-test19.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test19.ok"
cat << EOF > mcomm-test19.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 --no-location -o mcomm-test2.out \
mcomm-test2.in1 mcomm-test2.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test2.ok"
cat << EOF > mcomm-test2.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 -o mcomm-test20.out \
mcomm-test20.in1 mcomm-test20.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test20.ok"
cat << EOF > mcomm-test20.ok
tmpfiles="$tmpfiles mcomm-test21.out"
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 mcomm-test21.in1 mcomm-test21.in2 -o mcomm-test21.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test21.ok"
cat << EOF > mcomm-test21.ok
${MSGCOMM} --less-than=2 -o mcomm-test22.out \
mcomm-test22.in1 mcomm-test22.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test22.ok"
cat << EOF > mcomm-test22.ok
tmpfiles="$tmpfiles mcomm-23.out"
: ${MSGCOMM=msgcomm}
${MSGCOMM} -w 1000 mcomm-23.in1 mcomm-23.in2 -o mcomm-23.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
: ${DIFF=diff}
${DIFF} ${top_srcdir}/tests/msguniq-a.out mcomm-23.out
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 --omit-header -o mcomm-test3.out \
mcomm-test3.in1 mcomm-test3.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test3.ok"
cat << EOF > mcomm-test3.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 -o mcomm-test4.out \
mcomm-test4.in1 mcomm-test4.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test4.ok"
cat << EOF > mcomm-test4.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 --omit-header -o mcomm-test5.out \
mcomm-test5.in1 mcomm-test5.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test5.ok"
cat << EOF > mcomm-test5.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 --no-location -o mcomm-test6.out \
mcomm-test6.in1 mcomm-test6.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test6.ok"
cat << EOF > mcomm-test6.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=0 --no-location --omit-header -o mcomm-test7.out \
mcomm-test7.in1 mcomm-test7.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test7.ok"
cat << EOF > mcomm-test7.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=1 -o mcomm-test8.out \
mcomm-test8.in1 mcomm-test8.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test8.ok"
cat << EOF > mcomm-test8.ok
: ${MSGCOMM=msgcomm}
${MSGCOMM} --more-than=1 --no-location -o mcomm-test9.out \
mcomm-test9.in1 mcomm-test9.in2
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mcomm-test9.ok"
cat << EOF > mcomm-test9.ok
tmpfiles="$tmpfiles mco-test1.out"
: ${MSGCONV=msgconv}
${MSGCONV} --to-code=UTF-8 mco-test1.po -o mco-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mco-test1.ok"
cat <<EOF > mco-test1.ok
tmpfiles="$tmpfiles mco-test2.out"
: ${MSGCONV=msgconv}
${MSGCONV} -t Big5 mco-test2.po -o mco-test2.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mco-test2.ok"
cat <<EOF > mco-test2.ok
tmpfiles="$tmpfiles men-test1.out"
: ${MSGEN=msgen}
${MSGEN} men-test1.po -o men-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles men-test1.ok"
cat <<EOF > men-test1.ok
tmpfiles="$tmpfiles mex-test1.out"
: ${MSGEXEC=msgexec}
${MSGEXEC} -i mex-test1.po ./mex-test1.sh > mex-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mex-test1.ok"
cat <<EOF > mex-test1.ok
tmpfiles="$tmpfiles mex-test2.out"
: ${MSGEXEC=msgexec}
${MSGEXEC} -i mex-test2.po 0 > mex-test2.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
: ${CMP=cmp}
${CMP} mex-test2.ok mex-test2.out >/dev/null 2>/dev/null
#~ msgstr "das einen verheirateten Mann liebt"
EOF
-tmpfiles="$tmpfiles mfi-test1.out"
+tmpfiles="$tmpfiles mfi-test1.out mfi-test1.err"
: ${MSGFILTER=msgfilter}
LC_ALL=C \
-${MSGFILTER} -i mfi-test1.po -o mfi-test1.out fold -b -s -w 20 2>&1 \
- | grep -v 'warning: Locale charset' | grep -v '^ '
+${MSGFILTER} -i mfi-test1.po -o mfi-test1.out fold -b -s -w 20 >mfi-test1.err 2>&1
+result=$?
+cat mfi-test1.err | grep -v 'warning: Locale charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mfi-test1.ok"
cat <<EOF > mfi-test1.ok
#~ msgstr "das einen verheirateten Mann liebt"
EOF
-tmpfiles="$tmpfiles mfi-test2.out"
+tmpfiles="$tmpfiles mfi-test2.out mfi-test2.err"
: ${MSGFILTER=msgfilter}
sedexpr1='1{
s/^/\[\[/
s/$/\]\]/
}'
LC_ALL=C \
-${MSGFILTER} -i mfi-test2.po -o mfi-test2.out sed -e "$sedexpr1" -e "$sedexpr2" 2>&1 \
- | grep -v 'warning: Locale charset' | grep -v '^ '
+${MSGFILTER} -i mfi-test2.po -o mfi-test2.out sed -e "$sedexpr1" -e "$sedexpr2" >mfi-test2.err 2>&1
+result=$?
+cat mfi-test2.err | grep -v 'warning: Locale charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mfi-test2.ok"
cat <<EOF > mfi-test2.ok
tmpfiles="$tmpfiles modules.po"
: ${MSGCAT=msgcat} ${MSGFMT=msgfmt}
${MSGCAT} --use-first module1.po module2.po -o modules.po
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
${MSGFMT} modules.po -o LC_MESSAGES/gen.mo
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mf-test1.out"
: ${GETTEXT=gettext}
EOF
: ${MSGFMT=msgfmt}
-${MSGFMT} --check mf-test10.po1 -o /dev/null || \
- { rm -fr $tmpfiles; exit 1; }
+${MSGFMT} --check mf-test10.po1 -o /dev/null
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mf-test10.po2"
cat <<EOF > mf-test10.po2
tmpfiles="$tmpfiles modules.po"
: ${MSGCAT=msgcat} ${MSGFMT=msgfmt}
${MSGCAT} --use-first module1.po module2.po -o modules.po
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
${MSGFMT} modules.po -o LC_MESSAGES/gen.mo
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mf-test2.out"
: ${GETTEXT=gettext}
msgstr ""
EOF
-tmpfiles="$tmpfiles mftest3.mo"
+tmpfiles="$tmpfiles mftest3.mo mftest3.err"
: ${MSGFMT=msgfmt}
LC_MESSAGES=C LC_ALL= \
-${MSGFMT} mf-test3.po -o mftest3.mo 2>&1 \
- | grep -v 'warning: Charset' | grep -v '^ '
+${MSGFMT} mf-test3.po -o mftest3.mo >mftest3.err 2>&1
+result=$?
+cat mftest3.err | grep -v 'warning: Charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
test ! -f mftest3.mo
result=$?
tmpfiles="$tmpfiles foo-de.mo foo-fr.mo"
: ${MSGFMT=msgfmt}
${MSGFMT} foo.po
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles foo-de.out foo-fr.out"
: ${MSGUNFMT=msgunfmt}
${MSGUNFMT} foo-de.mo -o foo-de.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
${MSGUNFMT} foo-fr.mo -o foo-fr.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles foo-de.ok"
cat <<EOF > foo-de.ok
tmpfiles="$tmpfiles mg-test1.out"
: ${MSGGREP=msggrep}
${MSGGREP} -N pipe-bidi.c mg-test1.po -o mg-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mg-test1.ok"
cat <<\EOF > mg-test1.ok
tmpfiles="$tmpfiles mg-test2.out"
: ${MSGGREP=msggrep}
${MSGGREP} -M fr mg-test2.po -o mg-test2.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mg-test2.ok"
cat <<\EOF > mg-test2.ok
msgstr "Antiterror-Einheit"
EOF
-tmpfiles="$tmpfiles mg-test3.out"
+tmpfiles="$tmpfiles mg-test3.out mg-test3.err"
: ${MSGGREP=msggrep}
LC_MESSAGES=C LC_ALL= \
-${MSGGREP} -K -e error -T -e Speicher mg-test3.po -o mg-test3.out 2>&1 \
- | grep -v 'warning: Locale charset' | grep -v '^ '
+${MSGGREP} -K -e error -T -e Speicher mg-test3.po -o mg-test3.out >mg-test3.err 2>&1
+result=$?
+cat mg-test3.err | grep -v 'warning: Locale charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mg-test3.ok"
cat <<\EOF > mg-test3.ok
tmpfiles="$tmpfiles mg-test4.in2"
echo 'illegal' > mg-test4.in2
-tmpfiles="$tmpfiles mg-test4.out"
-
-tmpfiles="$tmpfiles mg-test4.out"
+tmpfiles="$tmpfiles mg-test4.out mg-test4.err"
: ${MSGGREP=msggrep}
LC_MESSAGES=C LC_ALL= \
-${MSGGREP} -K -e error -f mg-test4.in1 -f mg-test4.in2 -e cannot mg-test4.po -o mg-test4.out 2>&1 \
- | grep -v 'warning: Locale charset' | grep -v '^ '
+${MSGGREP} -K -e error -f mg-test4.in1 -f mg-test4.in2 -e cannot mg-test4.po -o mg-test4.out > mg-test4.err 2>&1
+result=$?
+cat mg-test4.err | grep -v 'warning: Locale charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mg-test4.ok"
cat <<\EOF > mg-test4.ok
tmpfiles="$tmpfiles mm-test1.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test1.in1 mm-test1.in2 -o mm-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test1.ok"
cat << EOF > mm-test1.ok
tmpfiles="$tmpfiles foo.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q foo.po foo.pot -o foo.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles foo.ok"
cat <<EOF > foo.ok
tmpfiles="$tmpfiles foo.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} --multi-domain -q foo.po foo.pot -o foo.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles foo.ok"
cat <<EOF > foo.ok
tmpfiles="$tmpfiles mm-test12.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q --compendium mm-test12.com /dev/null mm-test12.pot -o mm-test12.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test12.ok"
cat << EOF > mm-test12.ok
tmpfiles="$tmpfiles mm-test14.po~"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q --update mm-test14.po mm-test14.pot
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
: ${DIFF=diff}
${DIFF} mm-test14.bak mm-test14.po
tmpfiles="$tmpfiles mm-test15.po~"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q --update mm-test15.po mm-test15.pot
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test15.ok"
cat <<EOF > mm-test15.ok
tmpfiles="$tmpfiles mm-test16.po~"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q --update mm-test16.po mm-test16.pot
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test16.ok"
cat <<EOF > mm-test16.ok
tmpfiles="$tmpfiles mm-test17.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test17.po mm-test17.pot -o mm-test17.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test17.ok"
cat <<EOF > mm-test17.ok
tmpfiles="$tmpfiles mm-test18.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test18.po mm-test18.pot -o mm-test18.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test18.ok"
cat <<EOF > mm-test18.ok
tmpfiles="$tmpfiles mm-test19.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test19.po mm-test19.pot -o mm-test19.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test19.ok"
cat <<EOF > mm-test19.ok
tmpfiles="$tmpfiles mm-test20.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test20.po mm-test20.pot -o mm-test20.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test20.ok"
cat <<EOF > mm-test20.ok
tmpfiles="$tmpfiles mm-test3.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test3.in1 mm-test3.in2 -o mm-test3.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test3.ok"
cat << EOF > mm-test3.ok
tmpfiles="$tmpfiles mm-test4.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q mm-test4.in1.po mm-test4.in2.po -o mm-test4.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test4.ok"
cat <<EOF > mm-test4.ok
"blah blah blah blah blah blah blah blah blah blah blah blah blah bla bla bla\n"
EOF
-tmpfiles="$tmpfiles mm-test5.out"
+tmpfiles="$tmpfiles mm-test5.out mm-test5.err"
: ${MSGMERGE=msgmerge}
LC_MESSAGES=C LC_ALL= \
-${MSGMERGE} -q mm-test5.in1.po mm-test5.in2.po -o mm-test5.out 2>&1 \
- | grep -v 'warning: Charset' | grep -v '^ '
+${MSGMERGE} -q mm-test5.in1.po mm-test5.in2.po -o mm-test5.out >mm-test5.err 2>&1
+result=$?
+cat mm-test5.err | grep -v 'warning: Charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test5.ok"
cat <<EOF > mm-test5.ok
tmpfiles="$tmpfiles mm-test6.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q -C mm-test6.com mm-test6.in1 mm-test6.pot -o mm-test6.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test6.ok"
cat << EOF > mm-test6.ok
tmpfiles="$tmpfiles mm-test7.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q -C mm-test7.com mm-test7.in1 mm-test7.pot -o mm-test7.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test7.ok"
cat << EOF > mm-test7.ok
tmpfiles="$tmpfiles mm-test8.out"
: ${MSGMERGE=msgmerge}
${MSGMERGE} -q -C mm-test8.com mm-test8.in1 mm-test8.pot -o mm-test8.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test8.ok"
cat << EOF > mm-test8.ok
: ${MSGMERGE=msgmerge}
LC_MESSAGES=C LC_ALL= \
${MSGMERGE} -q mm-test9.in1.po mm-test9.in2.po -o mm-test9.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mm-test9.ok"
cat <<EOF > mm-test9.ok
tmpfiles="$tmpfiles mu-test1.mo"
: ${MSGFMT=msgfmt}
${MSGFMT} mu-test1.in -o mu-test1.mo
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles mu-test1.out"
: ${MSGUNFMT=msgunfmt}
${MSGUNFMT} mu-test1.mo -o mu-test1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
: ${DIFF=diff}
${DIFF} mu-test1.in mu-test1.out
tmpfiles="$tmpfiles msguniq-1.out"
: ${MSGUNIQ-msguniq}
${MSGUNIQ} -w 1000 ${top_srcdir}/tests/msguniq-a.in -o msguniq-1.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
: ${DIFF=diff}
${DIFF} ${top_srcdir}/tests/msguniq-a.out msguniq-1.out
tmpfiles="$tmpfiles msguniq-2.out"
: ${MSGUNIQ-msguniq}
${MSGUNIQ} -w 1000 -u ${top_srcdir}/tests/msguniq-a.in -o msguniq-2.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles msguniq-2.ok"
cat <<\EOF > msguniq-2.ok
tmpfiles="$tmpfiles msguniq-3.out"
: ${MSGUNIQ-msguniq}
${MSGUNIQ} -w 1000 -d ${top_srcdir}/tests/msguniq-a.in -o msguniq-3.out
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles msguniq-3.ok"
cat <<\EOF > msguniq-3.ok
: ${XGETTEXT=xgettext}
${XGETTEXT} -d xg-test1 -k_ --omit-header --no-location \
$top_srcdir/src/xgettext.c $top_srcdir/src/msgfmt.c $top_srcdir/src/gettext.c
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
: ${DIFF=diff}
${DIFF} $top_srcdir/tests/xg-test1.ok.po xg-test1.po
tmpfiles="$tmpfiles xg-test10.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location -c -d xg-test10 xg-test10.java
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test10.ok"
cat <<EOF > xg-test10.ok
tmpfiles="$tmpfiles xg-test11.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location -c --keyword-substring --keyword=Exception -d xg-test11 xg-test11.java
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test11.ok"
cat <<EOF > xg-test11.ok
tmpfiles="$tmpfiles xg-test12.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} -d xg-test12 -k_ --omit-header --no-location xg-test12.in.c
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test12.ok"
cat <<EOF > xg-test12.ok
tmpfiles="$tmpfiles xg-test15.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location -d xg-test15 xg-test15.java
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test15.ok"
cat <<EOF > xg-test15.ok
tmpfiles="$tmpfiles xg-test16.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location --keyword=ngettext:2,3 -d xg-test16 xg-test16.java
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test16.ok"
cat <<EOF > xg-test16.ok
tmpfiles="$tmpfiles xg-test17.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location -k:1,2 -d xg-test17 xg-test17.ycp
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test17.ok"
cat <<EOF > xg-test17.ok
tmpfiles="$tmpfiles xg-test2.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} -d xg-test2 -k_ --omit-header --no-location xg-test2.in.c
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test2.ok"
cat <<EOF > xg-test2.ok
tmpfiles=""
trap 'rm -fr $tmpfiles' 1 2 3 15
-tmpfiles="$tmpfiles zero-domain.po"
+tmpfiles="$tmpfiles zero-domain.po xg-test3.err"
rm -f zero-domain.po
: ${XGETTEXT=xgettext}
LC_MESSAGES=C LC_ALL= \
${XGETTEXT} -k_ -d zero-domain -x $top_srcdir/po/gettext.pot \
- $top_srcdir/src/xgettext.c 2>&1 \
- | grep -v 'warning: Charset' | grep -v '^ '
+ $top_srcdir/src/xgettext.c >xg-test3.err 2>&1
+result=$?
+cat xg-test3.err | grep -v 'warning: Charset' | grep -v '^ '
+test $result = 0 || { rm -fr $tmpfiles; exit 1; }
test ! -f zero-domain.po
result=$?
tmpfiles="$tmpfiles xg-test4.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --add-location xg-test4.in.c -d xg-test4
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test4.ok"
cat <<EOF > xg-test4.ok
tmpfiles="$tmpfiles xg-test5.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location --trigraphs xg-test5.in.c -d xg-test5
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test5.ok"
cat <<EOF > xg-test5.ok
tmpfiles="$tmpfiles xg-test6.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location --add-comments xg-test6.in.cc -d xg-test6
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test6.ok"
cat <<EOF > xg-test6.ok
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location --add-comments=XXX xg-test7.in.C \
-d xg-test7
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test7.ok"
cat <<EOF > xg-test7.ok
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header -n xg-test8.in.po \
xg-test8.c xg-test8.cc -d xg-test8
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test8.ok"
cat <<EOF > xg-test8.ok
tmpfiles="$tmpfiles xg-test9.po"
: ${XGETTEXT=xgettext}
${XGETTEXT} --omit-header --no-location -c --c++ -d xg-test9 xg-test9.c
+test $? = 0 || { rm -fr $tmpfiles; exit 1; }
tmpfiles="$tmpfiles xg-test9.ok"
cat <<EOF > xg-test9.ok