]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test-50-dissect: do not fail test on cleanup 24710/head
authorYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 17 Sep 2022 12:27:31 +0000 (21:27 +0900)
committerYu Watanabe <watanabe.yu+github@gmail.com>
Sat, 17 Sep 2022 12:36:18 +0000 (21:36 +0900)
These paths are read-only mount points. Hence, we cannot remove the
contents.

test/units/testsuite-50.sh

index f8a447d1d9b5d32c167eccc381c970da1d979611..f39383abc5d2132904454c940fbbb46273c1bbba 100755 (executable)
@@ -7,13 +7,17 @@ set -o pipefail
 
 export SYSTEMD_LOG_LEVEL=debug
 
-cleanup()
-{
+cleanup() {(
+    set +ex
+
     if [ -z "${image_dir}" ]; then
         return
     fi
+    umount "${image_dir}/app0"
+    umount "${image_dir}/app1"
+    umount "${image_dir}/app-nodistro"
     rm -rf "${image_dir}"
-}
+)}
 
 udevadm control --log-level=debug