app/test: update skipped count when setup returns skipped
Checks
Commit Message
If the setup function returns TEST_SKIPPED, the logs would say the test
case is skipped while the summary count would consider it under failed
cases. Address this by counting such test cases under 'skipped'.
Signed-off-by: Anoob Joseph <anoobj@marvell.com>
---
app/test/test.c | 2 ++
1 file changed, 2 insertions(+)
Comments
> Subject: [PATCH] app/test: update skipped count when setup returns skipped
>
> If the setup function returns TEST_SKIPPED, the logs would say the test
> case is skipped while the summary count would consider it under failed
> cases. Address this by counting such test cases under 'skipped'.
>
> Signed-off-by: Anoob Joseph <anoobj@marvell.com>
Acked-by: Akhil Goyal <gakhil@marvell.com>
25/05/2022 08:10, Akhil Goyal:
> > Subject: [PATCH] app/test: update skipped count when setup returns skipped
> >
> > If the setup function returns TEST_SKIPPED, the logs would say the test
> > case is skipped while the summary count would consider it under failed
> > cases. Address this by counting such test cases under 'skipped'.
> >
> > Signed-off-by: Anoob Joseph <anoobj@marvell.com>
> Acked-by: Akhil Goyal <gakhil@marvell.com>
Applied, thanks.
@@ -358,6 +358,8 @@ unit_test_suite_runner(struct unit_test_suite *suite)
suite->failed++;
} else if (test_success == -ENOTSUP) {
suite->unsupported++;
+ } else if (test_success == TEST_SKIPPED) {
+ suite->skipped++;
} else {
suite->failed++;
}