summaryrefslogtreecommitdiff
path: root/test/py/conftest.py
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2025-05-29 08:14:52 -0600
committerTom Rini <trini@konsulko.com>2025-06-12 11:32:29 -0600
commit2ab10ed2399b0c1c790733884935c94ad65aa2a8 (patch)
tree1ca6b965ddf0b3f10a20dfb8d848fe29ee988adf /test/py/conftest.py
parentef82e45c2ef5278493576708d6aafd686ba77af9 (diff)
test/py: Correct handling of exceptions
If an Unexpected exception is thrown in a test, an undefined variable error is reported. Fix this. Signed-off-by: Simon Glass <sjg@chromium.org> Fixes: 85d7dae377a ("test: Detect dead connections") Reviewed-by: Mattijs Korpershoek <mkorpershoek@kernel.org>
Diffstat (limited to 'test/py/conftest.py')
-rw-r--r--test/py/conftest.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/py/conftest.py b/test/py/conftest.py
index eec0b5488e4..8ce680a92a0 100644
--- a/test/py/conftest.py
+++ b/test/py/conftest.py
@@ -515,7 +515,7 @@ def ubman(request):
except BootFail as err:
handle_exception(ubconfig, ubman_fix, log, err, 'Boot fail', True,
ubman_fix.get_spawn_output())
- except Unexpected:
+ except Unexpected as err:
handle_exception(ubconfig, ubman_fix, log, err, 'Unexpected test output',
False)
return ubman_fix