test/py: Fix race conditions on EFI capsule tests
authorIlias Apalodimas <ilias.apalodimas@linaro.org>
Thu, 7 Aug 2025 08:08:16 +0000 (11:08 +0300)
committerTom Rini <trini@konsulko.com>
Mon, 18 Aug 2025 22:42:04 +0000 (16:42 -0600)
commitfa2a2e20d0b4d7af92ee118d66f3245055cc9ba3
tree1cdb21f13ac23ba085f3575fee2c5be62e693542
parent5096f81bda1cfac2a8a325e850442bf463be2f00
test/py: Fix race conditions on EFI capsule tests

efi_capsule_data() is called in each of the EFI tests to create and
setup the files we need. However, it also recreates the spi.bin file
that holds the SPI flash contents we rely on for the test validation.

This leads to weird errors since reading from the flash returns 0,
instead of the expected value if the file has been recreated.

Always restart our sandbox instance if the files are recreated.

Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org>
test/py/tests/test_efi_capsule/conftest.py