selftests/bpf: Correctly display subtest skip status
authorYucong Sun <fallentree@fb.com>
Tue, 17 Aug 2021 04:47:30 +0000 (21:47 -0700)
committerAndrii Nakryiko <andrii@kernel.org>
Tue, 17 Aug 2021 18:16:53 +0000 (11:16 -0700)
commitf667d1d66760fcb27aee6c9964eefde39a464afe
tree6ebf0879a3b699f79ee8979f654a69013e95cea1
parent26d82640d5ba2c3b32d79597be2dcf820ed78b16
selftests/bpf: Correctly display subtest skip status

In skip_account(), test->skip_cnt is set to 0 at the end, this makes next print
statement never display SKIP status for the subtest. This patch moves the
accounting logic after the print statement, fixing the issue.

This patch also added SKIP status display for normal tests.

Signed-off-by: Yucong Sun <fallentree@fb.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Link: https://lore.kernel.org/bpf/20210817044732.3263066-3-fallentree@fb.com
tools/testing/selftests/bpf/test_progs.c