test: e2e firmware update, and restarts told apart by boot time

With --reboot, a restore of the radio alone brings it back as it was:
on a board without Ethernet it read the radio from the wrong place.

--firmware <firmware.bin> updates the device through /updateFirmware and
checks it still runs a minute later, after it marks the update good.

wait_for_restart compared uptimes, so a test run right after another
restart could see more uptime than before and fail.  It compares boot
times, and waits while the device hasn't restarted yet.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
cjkas 2026-10-29 16:59:53 +01:00
parent 64f166490f
commit b525a800b0
5 changed files with 89 additions and 11 deletions

View file

@ -19,6 +19,7 @@ def pytest_addoption(parser):
parser.addoption("--shade", type=int, default=None, help="with --radio: the id of the shade the commands may move")
parser.addoption("--edit", action="store_true", help="also run the edits that change the shade model, then undo them")
parser.addoption("--reboot", action="store_true", help="also run the tests that reboot the device")
parser.addoption("--firmware", default=None, help="also update the device to this firmware.bin, built for its chip")
parser.addoption("--lockout", action="store_true", help="also run the test that locks this PC out of /login for 30 s")