aboutsummaryrefslogtreecommitdiffstats
path: root/tools/testing/selftests/bpf/test_progs.c
diff options
context:
space:
mode:
authorYucong Sun <fallentree@fb.com>2021-08-16 21:47:31 -0700
committerAndrii Nakryiko <andrii@kernel.org>2021-08-17 11:17:07 -0700
commit99c4fd8b92b3dc6db1afa0e252d3054d501a03ca (patch)
tree0f8fce2ad2c8baaa7ec689689ecc1ab14f0f7d33 /tools/testing/selftests/bpf/test_progs.c
parentselftests/bpf: Correctly display subtest skip status (diff)
downloadlinux-dev-99c4fd8b92b3dc6db1afa0e252d3054d501a03ca.tar.xz
linux-dev-99c4fd8b92b3dc6db1afa0e252d3054d501a03ca.zip
selftests/bpf: Also print test name in subtest status message
This patch add test name in subtest status message line, making it possible to grep ':OK' in the output to generate a list of passed test+subtest names, which can be processed to generate argument list to be used with "-a", "-d" exact string matching. Example: #1/1 align/mov:OK .. #1/12 align/pointer variable subtraction:OK #1 align:OK Signed-off-by: Yucong Sun <fallentree@fb.com> Signed-off-by: Andrii Nakryiko <andrii@kernel.org> Link: https://lore.kernel.org/bpf/20210817044732.3263066-4-fallentree@fb.com
Diffstat (limited to 'tools/testing/selftests/bpf/test_progs.c')
-rw-r--r--tools/testing/selftests/bpf/test_progs.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/tools/testing/selftests/bpf/test_progs.c b/tools/testing/selftests/bpf/test_progs.c
index f0fbead40883..90539b15b744 100644
--- a/tools/testing/selftests/bpf/test_progs.c
+++ b/tools/testing/selftests/bpf/test_progs.c
@@ -150,8 +150,8 @@ void test__end_subtest()
dump_test_log(test, sub_error_cnt);
- fprintf(env.stdout, "#%d/%d %s:%s\n",
- test->test_num, test->subtest_num, test->subtest_name,
+ fprintf(env.stdout, "#%d/%d %s/%s:%s\n",
+ test->test_num, test->subtest_num, test->test_name, test->subtest_name,
sub_error_cnt ? "FAIL" : (test->skip_cnt ? "SKIP" : "OK"));
if (sub_error_cnt)