scripts: ci: check_compliance: Capture failing tests

If a compliance test itself throws an exception, the entire script is
aborted.
Update this by capturing the exception and failing only the test itself.

Signed-off-by: Pieter De Gendt <pieter.degendt@basalte.be>
This commit is contained in:
Pieter De Gendt 2025-07-17 09:43:45 +02:00 committed by Anas Nashif
parent e71f79d644
commit 373c0724c9

View File

@ -2195,6 +2195,8 @@ def _main(args):
test.run()
except EndTest:
pass
except BaseException:
test.failure(f"An exception occurred in {test.name}:\n{traceback.format_exc()}")
# Annotate if required
if args.annotate: