summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHa Thach <[email protected]>2024-01-24 13:13:02 +0700
committerGitHub <[email protected]>2024-01-24 13:13:02 +0700
commit09ae91700c7441fe63726d08ebc126632436c92b (patch)
treedd6adb9ff9ce132762ec8e2583325d50a0f2b743
parentf92c2c2758e47c1dd9a0e441f1a48188171ae403 (diff)
parent9d0df8ebc5f643ff0b3dd06da14d11b3c1107a21 (diff)
Merge pull request #2424 from hathach/retry-hil-s3
Retry hil s3
-rw-r--r--.github/workflows/build_esp.yml2
-rw-r--r--.github/workflows/build_iar.yml2
-rw-r--r--.github/workflows/cmake_arm.yml2
-rw-r--r--test/hil/hil_test.py11
4 files changed, 15 insertions, 2 deletions
diff --git a/.github/workflows/build_esp.yml b/.github/workflows/build_esp.yml
index 33caa0edb..65ade7b03 100644
--- a/.github/workflows/build_esp.yml
+++ b/.github/workflows/build_esp.yml
@@ -8,6 +8,7 @@ on:
- 'examples/**'
- 'lib/**'
- 'hw/**'
+ - 'test/hil/**'
- '.github/workflows/build_esp.yml'
pull_request:
branches: [ master ]
@@ -16,6 +17,7 @@ on:
- 'examples/**'
- 'lib/**'
- 'hw/**'
+ - 'test/hil/**'
- '.github/workflows/build_esp.yml'
concurrency:
diff --git a/.github/workflows/build_iar.yml b/.github/workflows/build_iar.yml
index 9f2cc0351..a0a022ecc 100644
--- a/.github/workflows/build_iar.yml
+++ b/.github/workflows/build_iar.yml
@@ -9,6 +9,7 @@ on:
- 'lib/**'
- 'hw/**'
- 'tools/get_deps.py'
+ - 'test/hil/**'
- '.github/workflows/build_iar.yml'
pull_request:
branches: [ master ]
@@ -18,6 +19,7 @@ on:
- 'lib/**'
- 'hw/**'
- 'tools/get_deps.py'
+ - 'test/hil/**'
- '.github/workflows/build_iar.yml'
concurrency:
diff --git a/.github/workflows/cmake_arm.yml b/.github/workflows/cmake_arm.yml
index 8b87fef21..4ef2de4a6 100644
--- a/.github/workflows/cmake_arm.yml
+++ b/.github/workflows/cmake_arm.yml
@@ -8,6 +8,7 @@ on:
- 'examples/**'
- 'lib/**'
- 'hw/**'
+ - 'test/hil/**'
- 'tools/get_deps.py'
- '.github/workflows/cmake_arm.yml'
pull_request:
@@ -17,6 +18,7 @@ on:
- 'examples/**'
- 'lib/**'
- 'hw/**'
+ - 'test/hil/**'
- 'tools/get_deps.py'
- '.github/workflows/cmake_arm.yml'
diff --git a/test/hil/hil_test.py b/test/hil/hil_test.py
index 7c662aeea..7f03ce43f 100644
--- a/test/hil/hil_test.py
+++ b/test/hil/hil_test.py
@@ -364,8 +364,15 @@ def main(config_file, board):
print(f' {test} ...', end='')
- # flash firmware
- ret = globals()[f'flash_{flasher}'](item, fw)
+ # flash firmware. It may fail randomly, retry a few times
+ for i in range(3):
+ ret = globals()[f'flash_{flasher}'](item, fw)
+ if ret.returncode == 0:
+ break
+ else:
+ print(f'Flashing failed, retry {i+1}')
+ time.sleep(1)
+
assert ret.returncode == 0, 'Flash failed\n' + ret.stdout.decode()
# run test