tests: Skip checking for immutable bit on composefs
authorColin Walters <walters@verbum.org>
Wed, 30 Oct 2024 17:00:35 +0000 (13:00 -0400)
committerColin Walters <walters@verbum.org>
Wed, 30 Oct 2024 17:07:01 +0000 (13:07 -0400)
Needed changing after FCOS switch.

Signed-off-by: Colin Walters <walters@verbum.org>
tests/inst/src/sysroot.rs

index 6e65f35f183ee839cbfc37168bd28c04aa462bab..9f68f15f9263c4e3597d62f6627e02357c3d8e08 100644 (file)
@@ -43,6 +43,12 @@ pub(crate) fn itest_immutable_bit() -> Result<()> {
     if skip_non_ostree_host() {
         return Ok(());
     }
+    let sh = &xshell::Shell::new()?;
+    let fstype = cmd!(sh, "findmnt -n -o FSTYPE /").read()?;
+    // If we're on composefs then we're done
+    if fstype.as_str() == "overlay" {
+        return Ok(());
+    }
     // https://bugzilla.redhat.com/show_bug.cgi?id=1867601
     cmd_has_output(sh_inline::bash_command!("lsattr -d /").unwrap(), "-i-")?;
     Ok(())