]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
TEST-46-HOMED: Only run resize tests on btrfs
authorDaan De Meyer <daan.j.demeyer@gmail.com>
Mon, 6 May 2024 09:46:52 +0000 (11:46 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Mon, 6 May 2024 09:57:09 +0000 (11:57 +0200)
Other filesystems do not support online shrinking.

test/units/testsuite-46.sh

index 7d84b0d04d1f607112fa9c6e45e7fc6e4c1d5048..e4d2f7041035de4db6e183f53c70b68231032875 100755 (executable)
@@ -33,6 +33,8 @@ wait_for_state() {
     done
 }
 
+FSTYPE="$(stat --file-system --format "%T" /)"
+
 systemd-analyze log-level debug
 systemctl service-log-level systemd-homed debug
 
@@ -129,8 +131,9 @@ if ! systemd-detect-virt -cq ; then
         inspect test-user
 fi
 
-# Do some resize tests, but only if we run on real kernels, as quota inside of containers will fail
-if ! systemd-detect-virt -cq ; then
+# Do some resize tests, but only if we run on real kernels and are on btrfs, as quota inside of containers
+# will fail and minimizing while active only works on btrfs.
+if ! systemd-detect-virt -cq && [[ "$FSTYPE" == "btrfs" ]]; then
     # grow while inactive
     PASSWORD=xEhErW0ndafV4s homectl resize test-user 300M
     inspect test-user