]> diplodocus.org Git - nmh/blobdiff - test/inc/test-deb359167
Convert unqp() to decode_qp(), and make it a public function. Also,
[nmh] / test / inc / test-deb359167
index 72c6b7f91e9f159d1414411556c1e44e98264a38..e0360e3505fceef71a91c70a7e6ace955cdfddcb 100755 (executable)
@@ -2,19 +2,31 @@
 # Test a variant of a mailbox which caused debian bug 359167.
 set -e
 
 # Test a variant of a mailbox which caused debian bug 359167.
 set -e
 
-. ${MH_TEST_COMMON}
+if test -z "${MH_OBJ_DIR}"; then
+    srcdir=`dirname "$0"`/../..
+    MH_OBJ_DIR=`cd "$srcdir" && pwd`; export MH_OBJ_DIR
+fi
+
+. "$MH_OBJ_DIR/test/common.sh"
 
 setup_test
 
 
 setup_test
 
-THISDIR="${srcdir}/test/inc"
+# valgrind throws a strange error on FreeBSD >= 10; skip the test
+# for now while we try to track down the underlying cause.
+if [ `uname -s` = 'FreeBSD' ]; then
+  case `uname -r` in
+    1?.*) test_skip 'valgrind fails on FreeBSD >= 10' ;;
+  esac
+fi
 
 require_prog valgrind
 
 
 require_prog valgrind
 
+THISDIR="$srcdir/test/inc"
 TESTMBOX="$THISDIR/deb359167.mbox"
 
 TESTMBOX="$THISDIR/deb359167.mbox"
 
-if [ "$(output_md5 "$TESTMBOX" | cut -d ' ' -f 1)" != "e6ac458b8cccba2b2fd866fb505aeb5e" ]; then 
-  echo "Test mailbox has been corrupted"
-  exit 1
+if [ "`output_md5 "$TESTMBOX"`" != "e6ac458b8cccba2b2fd866fb505aeb5e" ]; then
+    echo "Test mailbox has been corrupted"
+    exit 1
 fi
 
 #
 fi
 
 #