selftests/bpf: Test_progs can read test lists from file
authorStephen Veiss <sveiss@meta.com>
Thu, 27 Apr 2023 22:53:33 +0000 (15:53 -0700)
committerAndrii Nakryiko <andrii@kernel.org>
Mon, 1 May 2023 22:30:02 +0000 (15:30 -0700)
commit64276f01dce85f72853617e513622b5645497d81
treef289291673a8b8c12d4c3d0da4beb163fdd3671c
parent0a5c0de8b66f9789422f04de7304e374a2ea8df5
selftests/bpf: Test_progs can read test lists from file

Improve test selection logic when using -a/-b/-d/-t options.
The list of tests to include or exclude can now be read from a file,
specified as @<filename>.

The file contains one name (or wildcard pattern) per line, and
comments beginning with # are ignored.

These options can be passed multiple times to read more than one file.

Signed-off-by: Stephen Veiss <sveiss@meta.com>
Signed-off-by: Andrii Nakryiko <andrii@kernel.org>
Acked-by: Yonghong Song <yhs@fb.com>
Link: https://lore.kernel.org/bpf/20230427225333.3506052-3-sveiss@meta.com
tools/testing/selftests/bpf/prog_tests/arg_parsing.c
tools/testing/selftests/bpf/test_progs.c
tools/testing/selftests/bpf/testing_helpers.c
tools/testing/selftests/bpf/testing_helpers.h