From d426e4345b44f0f4c8cd1ca4084a7a00526af7a9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Tor=20Arne=20Vestb=C3=B8?= Date: Mon, 17 Sep 2018 18:36:24 +0200 Subject: [PATCH] Ensure sparsebundlefs process is alive while we're waiting for it --- tests/10_basic.sh | 2 ++ tests/20_allow_other.sh | 2 ++ 2 files changed, 4 insertions(+) diff --git a/tests/10_basic.sh b/tests/10_basic.sh index 06aeb9c..08a5677 100644 --- a/tests/10_basic.sh +++ b/tests/10_basic.sh @@ -3,7 +3,9 @@ function setup() { test ! -z "$TEST_BUNDLE" mount_dir=$(mktemp -d) sparsebundlefs -s -f -D $TEST_BUNDLE $mount_dir & + pid=$! for i in {0..50}; do + kill -0 $pid >/dev/null 2>&1 # FIXME: Find actual mount callback in fuse? grep -q "bundle has" $test_output_file && break || sleep 0.1 done diff --git a/tests/20_allow_other.sh b/tests/20_allow_other.sh index f8a8293..451f37d 100644 --- a/tests/20_allow_other.sh +++ b/tests/20_allow_other.sh @@ -3,7 +3,9 @@ function setup() { test ! -z "$TEST_BUNDLE" mount_dir=$(mktemp -d) sparsebundlefs -s -f -D -o allow_other $TEST_BUNDLE $mount_dir & + pid=$! for i in {0..50}; do + kill -0 $pid >/dev/null 2>&1 # FIXME: Find actual mount callback in fuse? grep -q "bundle has" $test_output_file && break || sleep 0.1 done