From bc29bc9d63e5aaf56bd33be4c7165b94d514aa41 Mon Sep 17 00:00:00 2001 From: Caleb Connolly Date: Sat, 15 Jun 2024 18:59:55 +0200 Subject: [PATCH] tests: chroot: xfail chroot types that aren't tested (MR 2252) Signed-off-by: Caleb Connolly --- pmb/core/test_chroot.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/pmb/core/test_chroot.py b/pmb/core/test_chroot.py index 011b11a5..63d887e3 100644 --- a/pmb/core/test_chroot.py +++ b/pmb/core/test_chroot.py @@ -55,3 +55,12 @@ def test_invalid_chroots(pmb_args): Chroot(5) assert str(excinfo.value) == "Invalid chroot type: '5'" + +@pytest.mark.xfail +def test_untested_chroots(): + # IMAGE type is untested, name should be a valid path in this case + tested_chroot_types = [ChrootType.ROOTFS, ChrootType.BUILDROOT, ChrootType.NATIVE, + ChrootType.INSTALLER] + for ct in ChrootType: + if ct not in tested_chroot_types: + raise ValueError(f"ChrootType {ct} is untested!")