From: Kai Lueke Date: Tue, 28 Oct 2025 15:08:42 +0000 (+0900) Subject: test: Add missing test cleanup for the last sysext test X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6649562924f361edca98ce3d015bd7dcda97b076;p=thirdparty%2Fsystemd.git test: Add missing test cleanup for the last sysext test The last sysext test leaked things into new tests added later, uncovered by any new tests leftover check. Remove the mutable folder state through a trap as done in other tests. --- diff --git a/test/units/TEST-50-DISSECT.sysext.sh b/test/units/TEST-50-DISSECT.sysext.sh index 097e62df80f..f8472f5d301 100755 --- a/test/units/TEST-50-DISSECT.sysext.sh +++ b/test/units/TEST-50-DISSECT.sysext.sh @@ -1130,10 +1130,13 @@ extension_verify_after_unmerge "$fake_root" "$hierarchy" -h fake_root=${roots_dir:+"$roots_dir/mutable-directory-with-invalid-permissions"} hierarchy=/opt extension_data_dir="$fake_root/var/lib/extensions.mutable$hierarchy" +extension_data_dir_usr="$fake_root/var/lib/extensions.mutable/usr" prepare_root "$fake_root" "$hierarchy" prepare_extension_image "$fake_root" "$hierarchy" prepare_extension_mutable_dir "$extension_data_dir" +prepend_trap "rm -rf ${extension_data_dir@Q}" +prepend_trap "rm -rf ${extension_data_dir_usr@Q}" prepare_hierarchy "$fake_root" "$hierarchy" old_mode=$(stat --format '%#a' "$fake_root$hierarchy")