linux/lib/kunit
Brendan Higgins 5f3e062089 kunit: test: add support for test abort
Add support for aborting/bailing out of test cases, which is needed for
implementing assertions.

An assertion is like an expectation, but bails out of the test case
early if the assertion is not met. The idea with assertions is that you
use them to state all the preconditions for your test. Logically
speaking, these are the premises of the test case, so if a premise isn't
true, there is no point in continuing the test case because there are no
conclusions that can be drawn without the premises. Whereas, the
expectation is the thing you are trying to prove.

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: Stephen Boyd <sboyd@kernel.org>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
2019-09-30 17:35:01 -06:00
..
assert.c kunit: test: add assertion printing library 2019-09-30 17:35:00 -06:00
example-test.c kunit: test: add initial tests 2019-09-30 17:35:01 -06:00
Kconfig kunit: test: add initial tests 2019-09-30 17:35:01 -06:00
Makefile kunit: test: add support for test abort 2019-09-30 17:35:01 -06:00
string-stream-test.c kunit: test: add initial tests 2019-09-30 17:35:01 -06:00
string-stream.c kunit: test: add string_stream a std::stream like string builder 2019-09-30 17:35:00 -06:00
test.c kunit: test: add support for test abort 2019-09-30 17:35:01 -06:00
try-catch.c kunit: test: add support for test abort 2019-09-30 17:35:01 -06:00