mirror of
https://github.com/Fishwaldo/u-boot.git
synced 2025-03-21 06:31:31 +00:00
test: print_ut: Add test for %ls strings
Add a simple test for long strings. Signed-off-by: Rob Clark <robdclark@gmail.com> Reviewed-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
parent
0d3aaa35b8
commit
085391b223
1 changed files with 3 additions and 0 deletions
|
@ -36,6 +36,9 @@ static int do_ut_print(cmd_tbl_t *cmdtp, int flag, int argc,
|
||||||
snprintf(str, 0, "testing none");
|
snprintf(str, 0, "testing none");
|
||||||
assert(*str == 'x');
|
assert(*str == 'x');
|
||||||
|
|
||||||
|
sprintf(big_str, "_%ls_", L"foo");
|
||||||
|
assert(!strcmp("_foo_", big_str));
|
||||||
|
|
||||||
/* Test the banner function */
|
/* Test the banner function */
|
||||||
s = display_options_get_banner(true, str, sizeof(str));
|
s = display_options_get_banner(true, str, sizeof(str));
|
||||||
assert(s == str);
|
assert(s == str);
|
||||||
|
|
Loading…
Add table
Reference in a new issue