FreeBSD truncate(1) utility does not support the long option variant.
---
tests/test-blocksize.sh | 4 ++--
tests/test-fua.sh | 2 +-
tests/test-log.sh | 2 +-
3 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/tests/test-blocksize.sh b/tests/test-blocksize.sh
index de407c5..d239c9b 100755
--- a/tests/test-blocksize.sh
+++ b/tests/test-blocksize.sh
@@ -40,14 +40,14 @@ rm -f $files
# Prep images, and check that qemu-io understands the actions we plan on doing.
# TODO: Until we implement NBD_OPT_GO, qemu-io does its own read-modify-write
# at 512-byte alignment, while we'd like to ultimately test 1-byte accesses
-truncate --size 10M blocksize1.img
+truncate -s 10M blocksize1.img
if ! qemu-io -f raw -c 'r 0 1' -c 'w -z 1000 2000' \
-c 'w -P 0 1M 2M' -c 'discard 3M 4M' blocksize1.img; then
echo "$0: missing or broken qemu-io"
rm blocksize1.img
exit 77
fi
-truncate --size 10M blocksize2.img
+truncate -s 10M blocksize2.img
pid1= pid2=
diff --git a/tests/test-fua.sh b/tests/test-fua.sh
index 22a03ef..98b1e84 100755
--- a/tests/test-fua.sh
+++ b/tests/test-fua.sh
@@ -43,7 +43,7 @@ rm -f $files
# Prep images, and check that qemu-io understands the actions we plan on
# doing. We can't test trim+FUA, since qemu-io won't expose that.
-truncate --size 1M fua.img
+truncate -s 1M fua.img
if ! qemu-io -f raw -t none -c flush -c 'w -f -z 0 64k' fua.img; then
echo "$0: missing or broken qemu-io"
rm fua.img
diff --git a/tests/test-log.sh b/tests/test-log.sh
index 7b2c7be..877f9cc 100755
--- a/tests/test-log.sh
+++ b/tests/test-log.sh
@@ -37,7 +37,7 @@ files="log.img log.log log.sock log.pid"
rm -f $files
# Test that qemu-io works
-truncate --size 10M log.img
+truncate -s 10M log.img
if ! qemu-io -f raw -c 'w 1M 2M' log.img; then
echo "$0: missing or broken qemu-io"
exit 77
--
2.18.0