summaryrefslogtreecommitdiff
path: root/test/cmd_ut.c
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2021-05-08 15:59:58 +0300
committerTom Rini <trini@konsulko.com>2021-06-08 18:39:09 +0300
commitfbb99dcec099254f77efd7e16cdc5b31c46cc888 (patch)
treea86eeea28bb77c42d20c86fa109ad0249a26ad78 /test/cmd_ut.c
parent090d664eac6ff3bdb39c871bb9079df8e22873fc (diff)
downloadu-boot-fbb99dcec099254f77efd7e16cdc5b31c46cc888.tar.xz
test: Convert print tests to use ut framework
This test predates the test framework in U-Boot. It uses #define DEBUG and assert() to check the result. Update it to use the framework so it can report failure constitent with other tests. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'test/cmd_ut.c')
-rw-r--r--test/cmd_ut.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/test/cmd_ut.c b/test/cmd_ut.c
index b9c166045d..6f174c6a07 100644
--- a/test/cmd_ut.c
+++ b/test/cmd_ut.c
@@ -51,6 +51,7 @@ static struct cmd_tbl cmd_ut_sub[] = {
U_BOOT_CMD_MKENT(setexpr, CONFIG_SYS_MAXARGS, 1, do_ut_setexpr, "",
""),
#endif
+ U_BOOT_CMD_MKENT(print, CONFIG_SYS_MAXARGS, 1, do_ut_print, "", ""),
#ifdef CONFIG_UT_TIME
U_BOOT_CMD_MKENT(time, CONFIG_SYS_MAXARGS, 1, do_ut_time, "", ""),
#endif
@@ -132,6 +133,7 @@ static char ut_help_text[] =
#ifdef CONFIG_UT_OVERLAY
"ut overlay [test-name]\n"
#endif
+ "ut print [test-name] - test printing\n"
"ut setexpr [test-name] - test setexpr command\n"
#ifdef CONFIG_SANDBOX
"ut str - Basic test of string functions\n"