Skip to content

Commit

Permalink
tests: on_target: skip fota
Browse files Browse the repository at this point in the history
Skip fota when posting a job fails.

Signed-off-by: Giacomo Dematteis <[email protected]>
  • Loading branch information
DematteisGiacomo committed Sep 24, 2024
1 parent 9d21ece commit 1e61975
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/on_target/tests/test_fota.py
Original file line number Diff line number Diff line change
Expand Up @@ -41,11 +41,12 @@ def wait_for_fota_available(t91x_board):


def post_job(t91x_board, bundle_id, fota_type):
t91x_board.fota.post_fota_job(device_id=DEVICE_ID, type=fota_type, fingerprint=FOTADEVICE_FINGERPRINT, bundle_id=bundle_id)
result = t91x_board.fota.post_fota_job(device_id=DEVICE_ID, type=fota_type, fingerprint=FOTADEVICE_FINGERPRINT, bundle_id=bundle_id)
if not result:
pytest.skip("Failed to post FOTA job")
t91x_board.uart.flush()
wait_for_fota_available(t91x_board)


def run_fota_resumption(t91x_board, fota_type):
logger.debug(f"Testing fota resumption on disconnect for {fota_type} fota")
t91x_board.uart.wait_for_str("bytes (50%)")
Expand Down

0 comments on commit 1e61975

Please sign in to comment.