selftests: Extract single-test shell logic from lib.mk
authorKees Cook <keescook@chromium.org>
Wed, 24 Apr 2019 23:12:30 +0000 (16:12 -0700)
committerShuah Khan <skhan@linuxfoundation.org>
Thu, 25 Apr 2019 19:14:13 +0000 (13:14 -0600)
commit42d46e57ec9718c1090e43db75f433d0841af525
tree64ff0ca94762558142eae3f9f3a8ab68f268b81c
parentd917fb876f6eaeeea8a2b620d2a266ce26372f4d
selftests: Extract single-test shell logic from lib.mk

In order to improve the reusability of the kselftest test running logic,
this extracts the single-test logic from lib.mk into kselftest/runner.sh
which lib.mk can call directly. No changes in output.

As part of the change, this moves the "summary" Makefile logic around
to set a new "logfile" output. This will be used again in the future
"emit_tests" target as well.

Signed-off-by: Kees Cook <keescook@chromium.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/selftests/.gitignore
tools/testing/selftests/kselftest/runner.sh [new file with mode: 0644]
tools/testing/selftests/lib.mk