summaryrefslogtreecommitdiff
path: root/tests/stress_tests/fsstress-gocryptfs.bash
diff options
context:
space:
mode:
authorJakob Unterwurzacher2017-02-15 23:02:01 +0100
committerJakob Unterwurzacher2017-02-15 23:02:01 +0100
commitce2e610428c940c2bd5ca1790e7375117b1f6015 (patch)
tree08563c5e36b8d285390f897cd122e7e1aa8f6fc4 /tests/stress_tests/fsstress-gocryptfs.bash
parent6be7808992a1d9562b113b13831cd6d6a40114d6 (diff)
OSX compat: replace fusermount calls with fuse-unmount.bash
Mac OS X does not have fusermount and uses umount instead. The fuse-unmount.bash calls the appropriate command.
Diffstat (limited to 'tests/stress_tests/fsstress-gocryptfs.bash')
-rwxr-xr-xtests/stress_tests/fsstress-gocryptfs.bash9
1 files changed, 6 insertions, 3 deletions
diff --git a/tests/stress_tests/fsstress-gocryptfs.bash b/tests/stress_tests/fsstress-gocryptfs.bash
index 51c68db..432899a 100755
--- a/tests/stress_tests/fsstress-gocryptfs.bash
+++ b/tests/stress_tests/fsstress-gocryptfs.bash
@@ -14,6 +14,10 @@
set -eu
+cd "$(dirname "$0")"
+MYNAME=$(basename $0)
+source ../fuse-unmount.bash
+
# Backing directory
DIR=$(mktemp -d /tmp/fsstress.XXX)
# Mountpoint
@@ -28,13 +32,12 @@ then
fi
# Setup
-fusermount -u -z $MNT &> /dev/null || true
+fuse-unmount -z $MNT &> /dev/null || true
mkdir -p $DIR $MNT
rm -Rf $DIR/*
rm -Rf $MNT/*
# FS-specific compile and mount
-MYNAME=$(basename $0)
if [ $MYNAME = fsstress-loopback.bash ]; then
echo "Recompile go-fuse loopback"
cd $GOPATH/src/github.com/hanwen/go-fuse/example/loopback
@@ -62,7 +65,7 @@ done
echo
# Cleanup trap
-trap "kill %1 ; cd /; fusermount -u -z $MNT; rm -rf $DIR $MNT" EXIT
+trap "kill %1 ; cd /; fuse-unmount -z $MNT; rm -rf $DIR $MNT" EXIT
echo "Starting fsstress loop"
N=1