test/py: Handle a failure during configuration
If the build does not exist we can get an error when starting up:
INTERNALERROR> Exception: .config does not exist; try passing --build
option?
Exception ignored in atexit callback: <function cleanup at ...>
Traceback (most recent call last):
File "test/py/conftest.py", line 697, in cleanup
show_timings()
File "test/py/conftest.py", line 644, in show_timings
if ubconfig and ubconfig.timing:
^^^^^^^^^^^^^^^
Fix this by setting up the timing member at the start.
Signed-off-by: Simon Glass <simon.glass@canonical.com>
This commit is contained in:
@@ -301,6 +301,7 @@ def pytest_configure(config):
|
||||
ubconfig = ArbitraryAttributeContainer()
|
||||
ubconfig.brd = dict()
|
||||
ubconfig.env = dict()
|
||||
ubconfig.timing = None
|
||||
not_found = []
|
||||
|
||||
with log.section('Loading lab modules', 'load_modules'):
|
||||
|
||||
Reference in New Issue
Block a user