tests: df: check that -k and -m are supported

* tests/df/df-output.sh: Check that the block size is correct when using
-k and -m.
This commit is contained in:
Collin Funk committed 2026-08-18 19:41:33 -07:00
1 parent 554d2cdc6f
commit ffa26f0c2f
1 file changed
+18
+18
View File
@@ -98,6 +98,24 @@ sed -e '1 {
}' out > out2
compare exp out2 || fail=1
df -k --output=size '.' >out || fail=1
sed -e '1 {
s/ *//
q
}' out > out2
compare exp out2 || fail=1
cat <<\EOF > exp || framework_failure_
1M-blocks
EOF
df -m --output=size '.' >out || fail=1
sed -e '1 {
s/ *//
q
}' out > out2
compare exp out2 || fail=1
# Ensure that the grand total line now contains a "-" in the TARGET field ...
cat <<\EOF > exp || framework_failure_
-