[PATCH 3/5] patman: test_util: Use unittest text runner to print test results
Simon Glass
sjg at chromium.org
Tue Apr 19 23:54:16 CEST 2022
On Sat, 2 Apr 2022 at 11:06, Alper Nebi Yasak <alpernebiyasak at gmail.com> wrote:
>
> The python tools' test utilities handle printing test results, but the
> output is quite bare compared to an ordinary unittest run. Delegate
> printing the results to a unittest text runner, which gives us niceties
> like clear separation between each test's result and how long it took to
> run the test suite.
>
> Unfortunately it does not print info for skipped tests by default, but
> this can be handled later by a custom test result subclass. It also does
> not print the tool name; manually print a heading that includes the
> toolname so that the outputs of each tool's tests are distinguishable in
> the CI output.
>
> Signed-off-by: Alper Nebi Yasak <alpernebiyasak at gmail.com>
> ---
>
> tools/binman/main.py | 8 ++----
> tools/buildman/main.py | 8 ++----
> tools/dtoc/main.py | 9 +++---
> tools/dtoc/test_fdt.py | 8 +++---
> tools/patman/main.py | 8 ++----
> tools/patman/test_util.py | 58 ++++++++++++++-------------------------
> 6 files changed, 38 insertions(+), 61 deletions(-)
>
Reviewed-by: Simon Glass <sjg at chromium.org>
More information about the U-Boot
mailing list