kunit: tool: print failed tests only
authorRae Moar <rmoar@google.com>
Wed, 13 Nov 2024 22:24:06 +0000 (22:24 +0000)
committerShuah Khan <skhan@linuxfoundation.org>
Tue, 19 Nov 2024 21:52:17 +0000 (14:52 -0700)
commit3c67a2c09b3c32fd9fc5caf2afacd15267d08071
tree355ffb616ae3b5a41f2c32907c8da713639a2645
parent062a9dd9bad7d802a6f6f23b09118b69d8766c61
kunit: tool: print failed tests only

Add flag --failed to kunit.py to print only failed tests. This printing
is done after running is over.

This patch also adds the method print_test() that will also print your
Test object. Before, all printing of tests occurred during parsing. This
method could be useful in the future when converting to/from KTAP to this
pretty-print output.

Link: https://lore.kernel.org/r/20241113222406.1590372-2-rmoar@google.com
Signed-off-by: Rae Moar <rmoar@google.com>
Reviewed-by: David Gow <davidgow@google.com>
Signed-off-by: Shuah Khan <skhan@linuxfoundation.org>
tools/testing/kunit/kunit.py
tools/testing/kunit/kunit_parser.py
tools/testing/kunit/kunit_tool_test.py