test: Move stat-printing into its own function
Add a function to show the stats, so we can decide when to print it. This slightly adjusts the output, so that any 'test not found' message appears on its own line after all other output. The 'failures' message now appears in lower case so update pytest accordingly. Signed-off-by: Simon Glass <sjg@chromium.org>
This commit is contained in:
@@ -36,7 +36,7 @@ def test_spl(u_boot_console, ut_spl_subtest):
|
||||
cons = u_boot_console
|
||||
cons.restart_uboot_with_flags(['-u', '-k', ut_spl_subtest.split()[1]])
|
||||
output = cons.get_spawn_output().replace('\r', '')
|
||||
assert 'Failures: 0' in output
|
||||
assert 'failures: 0' in output
|
||||
finally:
|
||||
# Restart afterward in case a non-SPL test is run next. This should not
|
||||
# happen since SPL tests are run in their own invocation of test.py, but
|
||||
|
||||
Reference in New Issue
Block a user