mirror of
https://source.denx.de/u-boot/u-boot.git
synced 2025-10-09 22:51:27 +02:00
dm: test: Improve partition test error output
Improve the logging when the partition test fails so that it is clear what went wrong, shown with actual values. Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
19c961e21c
commit
44ef2855e1
@ -17,10 +17,12 @@ static int do_test(struct unit_test_state *uts, int expected,
|
||||
struct blk_desc *mmc_dev_desc;
|
||||
struct disk_partition part_info;
|
||||
|
||||
ut_asserteq(expected,
|
||||
part_get_info_by_dev_and_name_or_num("mmc", part_str,
|
||||
&mmc_dev_desc,
|
||||
&part_info, whole));
|
||||
int ret = part_get_info_by_dev_and_name_or_num("mmc", part_str,
|
||||
&mmc_dev_desc,
|
||||
&part_info, whole);
|
||||
|
||||
ut_assertf(expected == ret, "test(%d, \"%s\", %d) == %d", expected,
|
||||
part_str, whole, ret);
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user