kunit: test: add KUnit test runner core
authorBrendan Higgins <brendanhiggins@google.com>
Mon, 23 Sep 2019 09:02:31 +0000 (02:02 -0700)
committerShuah Khan <skhan@linuxfoundation.org>
Mon, 30 Sep 2019 23:35:00 +0000 (17:35 -0600)
commit914cc63eea6fbe11ed46dba5e4438d81b0cd42d2
treee7fc4cb9f934029677338053cf802c6937abeedb
parent54ecb8f7028c5eb3d740bb82b0f1d90f2df63c5c
kunit: test: add KUnit test runner core

Add core facilities for defining unit tests; this provides a common way
to define test cases, functions that execute code which is under test
and determine whether the code under test behaves as expected; this also
provides a way to group together related test cases in test suites (here
we call them test_modules).

Just define test cases and how to execute them for now; setting
expectations on code will be defined later.

Signed-off-by: Brendan Higgins <brendanhiggins@google.com>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Reviewed-by: Logan Gunthorpe <logang@deltatee.com>
Reviewed-by: Luis Chamberlain <mcgrof@kernel.org>
Reviewed-by: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
include/kunit/test.h [new file with mode: 0644]
lib/kunit/Kconfig [new file with mode: 0644]
lib/kunit/Makefile [new file with mode: 0644]
lib/kunit/test.c [new file with mode: 0644]