diff --git a/tests/test_argument_parsing.py b/tests/test_argument_parsing.py index 6da3e8fcd..d05291804 100644 --- a/tests/test_argument_parsing.py +++ b/tests/test_argument_parsing.py @@ -813,37 +813,72 @@ def test_disk_image_path(target, expected_name): ("target", "config_options", "expected_kernels"), [ # RISCV kernconf tests - pytest.param("cheribsd-riscv64-purecap", ["--cheribsd/no-build-alternate-abi-kernels"], ["CHERI-QEMU"]), + pytest.param( + "cheribsd-riscv64-purecap", + ["--cheribsd/no-build-alternate-abi-kernels"], + ["CHERI-PURECAP-QEMU"], + ), pytest.param( "cheribsd-riscv64-purecap", ["--cheribsd/build-fpga-kernels"], - ["CHERI-QEMU", "CHERI-PURECAP-QEMU"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-QEMU", + ], + ), + pytest.param( + "cheribsd-riscv64-purecap", + [], + [ + "CHERI-PURECAP-QEMU", + "CHERI-QEMU", + ] ), - pytest.param("cheribsd-riscv64-purecap", [], ["CHERI-QEMU", "CHERI-PURECAP-QEMU"]), pytest.param( "cheribsd-riscv64-purecap", ["--cheribsd/build-alternate-abi-kernels", "--cheribsd/default-kernel-abi", "purecap"], - ["CHERI-PURECAP-QEMU", "CHERI-QEMU"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-QEMU", + ], ), pytest.param( "cheribsd-riscv64-purecap", - ["--cheribsd/build-fett-kernels", "--cheribsd/no-build-alternate-abi-kernels"], - ["CHERI-QEMU", "CHERI-QEMU-FETT"], + [ + "--cheribsd/build-fett-kernels", + "--cheribsd/no-build-alternate-abi-kernels"], + [ + "CHERI-PURECAP-QEMU", + ], ), pytest.param( "cheribsd-riscv64-purecap", ["--cheribsd/build-fett-kernels"], - ["CHERI-QEMU", "CHERI-QEMU-FETT", "CHERI-PURECAP-QEMU"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-QEMU", + "CHERI-QEMU-FETT", + ], ), pytest.param( "cheribsd-riscv64-purecap", - ["--cheribsd/build-bench-kernels", "--cheribsd/no-build-alternate-abi-kernels"], - ["CHERI-QEMU", "CHERI-QEMU-NODEBUG"], + [ + "--cheribsd/build-bench-kernels", + "--cheribsd/no-build-alternate-abi-kernels"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-PURECAP-QEMU-NODEBUG", + ], ), pytest.param( "cheribsd-riscv64-purecap", ["--cheribsd/build-bench-kernels"], - ["CHERI-QEMU", "CHERI-QEMU-NODEBUG", "CHERI-PURECAP-QEMU", "CHERI-PURECAP-QEMU-NODEBUG"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-PURECAP-QEMU-NODEBUG", + "CHERI-QEMU", + "CHERI-QEMU-NODEBUG", + ], ), pytest.param( "cheribsd-riscv64-purecap", @@ -852,12 +887,21 @@ def test_disk_image_path(target, expected_name): "--cheribsd/build-fpga-kernels", "--cheribsd/no-build-alternate-abi-kernels", ], - ["CHERI-QEMU", "CHERI-QEMU-FETT", "CHERI-FETT"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-PURECAP-FETT", + ], ), pytest.param( "cheribsd-riscv64-purecap", ["--cheribsd/build-fett-kernels", "--cheribsd/build-fpga-kernels"], - ["CHERI-QEMU", "CHERI-QEMU-FETT", "CHERI-PURECAP-QEMU", "CHERI-FETT", "CHERI-PURECAP-FETT"], + [ + "CHERI-PURECAP-QEMU", + "CHERI-QEMU", + "CHERI-QEMU-FETT", + "CHERI-PURECAP-FETT", + "CHERI-FETT", + ], ), pytest.param( "cheribsd-riscv64-purecap", @@ -866,8 +910,16 @@ def test_disk_image_path(target, expected_name): ), # Morello kernconf tests pytest.param("cheribsd-aarch64", [], ["GENERIC"]), - pytest.param("cheribsd-morello-purecap", ["--cheribsd/no-build-alternate-abi-kernels"], ["GENERIC-MORELLO"]), - pytest.param("cheribsd-morello-purecap", [], ["GENERIC-MORELLO", "GENERIC-MORELLO-PURECAP"]), + pytest.param( + "cheribsd-morello-purecap", + ["--cheribsd/no-build-alternate-abi-kernels"], + ["GENERIC-MORELLO-PURECAP"] + ), + pytest.param( + "cheribsd-morello-purecap", + [], + ["GENERIC-MORELLO-PURECAP", "GENERIC-MORELLO"] + ), pytest.param( "cheribsd-morello-purecap", ["--cheribsd-morello-purecap/kernel-config", "CUSTOM-KERNEL-CONFIG"], @@ -908,12 +960,20 @@ def test_kernel_configs(target, config_options: "list[str]", expected_kernels: " "--cheribsd-mfs-root-kernel-riscv64-purecap/build-fpga-kernels", "--cheribsd-mfs-root-kernel-riscv64-purecap/no-build-alternate-abi-kernels", ], - ["CHERI-QEMU-MFS-ROOT", "CHERI-GFE"], + [ + "CHERI-PURECAP-QEMU-MFS-ROOT", + "CHERI-PURECAP-GFE" + ], ), pytest.param( "cheribsd-mfs-root-kernel-riscv64-purecap", ["--cheribsd-mfs-root-kernel-riscv64-purecap/build-fpga-kernels"], - ["CHERI-QEMU-MFS-ROOT", "CHERI-PURECAP-QEMU-MFS-ROOT", "CHERI-GFE", "CHERI-PURECAP-GFE"], + [ + "CHERI-PURECAP-QEMU-MFS-ROOT", + "CHERI-QEMU-MFS-ROOT", + "CHERI-PURECAP-GFE", + "CHERI-GFE", + ], ), pytest.param( "cheribsd-mfs-root-kernel-riscv64-purecap", @@ -938,10 +998,10 @@ def test_kernel_configs(target, config_options: "list[str]", expected_kernels: " "cheribsd-mfs-root-kernel-riscv64-purecap", ["--cheribsd/build-nocaprevoke-kernel"], [ - "CHERI-QEMU-MFS-ROOT", - "CHERI-NOCAPREVOKE-QEMU-MFS-ROOT", "CHERI-PURECAP-QEMU-MFS-ROOT", "CHERI-PURECAP-NOCAPREVOKE-QEMU-MFS-ROOT", + "CHERI-QEMU-MFS-ROOT", + "CHERI-NOCAPREVOKE-QEMU-MFS-ROOT", ], ), ], @@ -1273,7 +1333,7 @@ def test_mfs_root_kernel_inherits_defaults_from_cheribsd(): ], ) assert cheribsd_riscv64_purecap.kernel_config == "BASE_CONFIG_RISCV64" - assert cheribsd_riscv64_hybrid.kernel_config == "CHERI-QEMU" + assert cheribsd_riscv64_hybrid.kernel_config == "CHERI-PURECAP-QEMU" assert mfs_riscv64.kernel_config is None assert mfs_riscv64_hybrid.kernel_config == "MFS_CONFIG_RISCV64_HYBRID" _parse_arguments(