diff options
Diffstat (limited to 'test/boot')
-rw-r--r-- | test/boot/bootflow.c | 4 | ||||
-rw-r--r-- | test/boot/bootmeth.c | 13 | ||||
-rw-r--r-- | test/boot/vbe_fixup.c | 2 |
3 files changed, 13 insertions, 6 deletions
diff --git a/test/boot/bootflow.c b/test/boot/bootflow.c index 1e8ea754bc..e1e0708210 100644 --- a/test/boot/bootflow.c +++ b/test/boot/bootflow.c @@ -330,7 +330,7 @@ static int bootflow_system(struct unit_test_state *uts) struct udevice *dev; if (!IS_ENABLED(CONFIG_CMD_BOOTEFI_BOOTMGR)) - return 0; + return -EAGAIN; ut_assertok(uclass_get_device_by_name(UCLASS_BOOTMETH, "efi_mgr", &dev)); sandbox_set_fake_efi_mgr_dev(dev, true); @@ -395,7 +395,7 @@ BOOTSTD_TEST(bootflow_iter_disable, UT_TESTF_DM | UT_TESTF_SCAN_FDT); static int bootflow_scan_glob_bootmeth(struct unit_test_state *uts) { if (!IS_ENABLED(CONFIG_BOOTMETH_GLOBAL)) - return 0; + return -EAGAIN; ut_assertok(bootstd_test_drop_bootdev_order(uts)); diff --git a/test/boot/bootmeth.c b/test/boot/bootmeth.c index f0b5ab9adb..0098ef3efd 100644 --- a/test/boot/bootmeth.c +++ b/test/boot/bootmeth.c @@ -103,10 +103,17 @@ static int bootmeth_cmd_order(struct unit_test_state *uts) ut_asserteq_str("efi syslinux", env_get("bootmeths")); ut_assert_console_end(); - /* Try with global bootmeths */ + return 0; +} +BOOTSTD_TEST(bootmeth_cmd_order, UT_TESTF_DM | UT_TESTF_SCAN_FDT); + +/* Check 'bootmeth order' command with global bootmeths */ +static int bootmeth_cmd_order_glob(struct unit_test_state *uts) +{ if (!IS_ENABLED(CONFIG_BOOTMETH_GLOBAL)) - return 0; + return -EAGAIN; + console_record_reset_enable(); ut_assertok(run_command("bootmeth order \"efi firmware0\"", 0)); ut_assert_console_end(); ut_assertok(run_command("bootmeth list", 0)); @@ -122,7 +129,7 @@ static int bootmeth_cmd_order(struct unit_test_state *uts) return 0; } -BOOTSTD_TEST(bootmeth_cmd_order, UT_TESTF_DM | UT_TESTF_SCAN_FDT); +BOOTSTD_TEST(bootmeth_cmd_order_glob, UT_TESTF_DM | UT_TESTF_SCAN_FDT); /* Check 'bootmeths' env var */ static int bootmeth_env(struct unit_test_state *uts) diff --git a/test/boot/vbe_fixup.c b/test/boot/vbe_fixup.c index 1b488e25ab..7f0f809499 100644 --- a/test/boot/vbe_fixup.c +++ b/test/boot/vbe_fixup.c @@ -26,7 +26,7 @@ static int vbe_test_fixup(struct unit_test_state *uts) * flat tree, since device tree fix-ups do not yet support live tree. */ if (!working_fdt) - return 0; + return -EAGAIN; tree = oftree_from_fdt(working_fdt); ut_assert(oftree_valid(tree)); |