diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2024-03-28 12:24:50 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2024-03-28 12:25:28 -0400 |
commit | ff1b3d12cb798477b64c09cc0e3b9b2b6bc3e9da (patch) | |
tree | ee07aa390ad25c6286e95193a8e5d118debdfe69 /tests/bsd/sparse.sh | |
parent | 2fc0b4425197099ba5575d3b50ac77b51c0e0a95 (diff) | |
download | bfs-ff1b3d12cb798477b64c09cc0e3b9b2b6bc3e9da.tar.xz |
tests/bsd: Add a -sparse test
Diffstat (limited to 'tests/bsd/sparse.sh')
-rw-r--r-- | tests/bsd/sparse.sh | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/bsd/sparse.sh b/tests/bsd/sparse.sh new file mode 100644 index 0000000..7fcdeed --- /dev/null +++ b/tests/bsd/sparse.sh @@ -0,0 +1,12 @@ +test "$UNAME" = "Linux" || skip + +cd "$TEST" +mkdir mnt + +bfs_sudo mount -t tmpfs tmpfs mnt || skip +defer bfs_sudo umount mnt + +truncate -s 1M mnt/sparse +dd if=/dev/zero of=mnt/dense bs=1M count=1 + +bfs_diff mnt -type f -sparse |