summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorEvgeny Bachinin <EABachinin@sberdevices.ru>2023-03-20 11:23:14 +0300
committerTom Rini <trini@konsulko.com>2023-03-30 15:09:59 -0400
commit49b7d69f56d2f0ecb357079708603cf9df0b3699 (patch)
tree423a4166c3d9570e1ef0cae3260eacb768e79099 /test
parent0d73c238425bb6218b38d0d35c950b03230e2e5a (diff)
downloadu-boot-49b7d69f56d2f0ecb357079708603cf9df0b3699.tar.gz
u-boot-49b7d69f56d2f0ecb357079708603cf9df0b3699.tar.bz2
u-boot-49b7d69f56d2f0ecb357079708603cf9df0b3699.zip
test: exit: fix run_commandf() warnings
Fix warnings after adding printf-like attribute format for run_commandf(): warning: too many arguments for format [-Wformat-extra-args] Signed-off-by: Evgeny Bachinin <EABachinin@sberdevices.ru> Reviewed-by: Simon Glass <sjg@chromium.org> Reviewed-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'test')
-rw-r--r--test/cmd/exit.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/test/cmd/exit.c b/test/cmd/exit.c
index ca34abef89..7e160f7e4b 100644
--- a/test/cmd/exit.c
+++ b/test/cmd/exit.c
@@ -60,20 +60,20 @@ static int cmd_exit_test(struct unit_test_state *uts)
/* Validate that 'exit' behaves the same way as 'exit 0' */
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; exit ; echo baz' ; run foo ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; exit ; echo baz' ; run foo ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("0");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; exit ; echo baz' ; run foo && echo quux ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; exit ; echo baz' ; run foo && echo quux ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("quux");
ut_assert_nextline("0");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; exit ; echo baz' ; run foo || echo quux ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; exit ; echo baz' ; run foo || echo quux ; echo $?"));
ut_assert_nextline("bar");
/* Either 'exit' returns 0, or 'echo quux' returns 0 */
ut_assert_nextline("0");
@@ -81,39 +81,39 @@ static int cmd_exit_test(struct unit_test_state *uts)
/* Validate that return value still propagates from 'run' command */
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; true' ; run foo ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; true' ; run foo ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("0");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; true' ; run foo && echo quux ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; true' ; run foo && echo quux ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("quux");
ut_assert_nextline("0");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; true' ; run foo || echo quux ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; true' ; run foo || echo quux ; echo $?"));
ut_assert_nextline("bar");
/* The 'true' returns 0 */
ut_assert_nextline("0");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; false' ; run foo ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; false' ; run foo ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("1");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; false' ; run foo && echo quux ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; false' ; run foo && echo quux ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("1");
ut_assertok(ut_check_console_end(uts));
ut_assertok(console_record_reset_enable());
- ut_assertok(run_commandf("setenv foo 'echo bar ; false' ; run foo || echo quux ; echo $?", i));
+ ut_assertok(run_commandf("setenv foo 'echo bar ; false' ; run foo || echo quux ; echo $?"));
ut_assert_nextline("bar");
ut_assert_nextline("quux");
/* The 'echo quux' returns 0 */