From d96f94fedee0781d474beaa0038beea277bd0567 Mon Sep 17 00:00:00 2001 From: Michael Vogt Date: Tue, 16 Jan 2024 11:14:43 +0100 Subject: [PATCH] test: fix new mount tests under rhel8 The new `create_image_with_partitions()` helper fails under rhel8 currently. The reason is that `mkfs.ext4 -E offset=` will warn in older versions about a partition table and require user input. This got fixed `e2fsprogs` 1.46.3 in Jul 2021 but RHEL8 still has 1.45. [0] https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=989612 --- test/run/test_mount.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/run/test_mount.py b/test/run/test_mount.py index a4a4e987..0a7a3d45 100755 --- a/test/run/test_mount.py +++ b/test/run/test_mount.py @@ -178,8 +178,8 @@ def create_image_with_partitions(tmp_path): ["parted", "--script", img, "mklabel", "msdos"], ["parted", "--script", img, "mkpart", "primary", "ext4", "1MiB", "10Mib"], ["parted", "--script", img, "mkpart", "primary", "ext4", "10MiB", "19Mib"], - ["mkfs.ext4", "-E", f"offset={1*1024*1024}", img, "9M"], - ["mkfs.ext4", "-E", f"offset={10*1024*1024}", img, "9M"], + ["mkfs.ext4", "-F", "-E", f"offset={1*1024*1024}", img, "9M"], + ["mkfs.ext4", "-F", "-E", f"offset={10*1024*1024}", img, "9M"], ]: subprocess.check_call(cmd) return tree, img.name