#! /bin/sh
+. "${srcdir=.}/init.sh"; path_prepend_ . ../src
# Test general operation.
-tmpfiles=""
-trap 'rm -fr $tmpfiles' 1 2 3 15
-
-tmpfiles="$tmpfiles msguniq-1.tmp msguniq-1.out"
: ${MSGUNIQ-msguniq}
-${MSGUNIQ} -w 1000 -o msguniq-1.tmp ${top_srcdir}/tests/msguniq-a.in
-test $? = 0 || { rm -fr $tmpfiles; exit 1; }
-LC_ALL=C tr -d '\r' < msguniq-1.tmp > msguniq-1.out
-test $? = 0 || { rm -fr $tmpfiles; exit 1; }
+${MSGUNIQ} -w 1000 -o msguniq-1.tmp "$abs_srcdir"/msguniq-a.in || exit 1
+LC_ALL=C tr -d '\r' < msguniq-1.tmp > msguniq-1.out || exit 1
: ${DIFF=diff}
-${DIFF} ${top_srcdir}/tests/msguniq-a.out msguniq-1.out
+${DIFF} "$abs_srcdir"/msguniq-a.out msguniq-1.out
result=$?
-rm -fr $tmpfiles
-
exit $result