forked from wolfSSL/wolfssl
Retry hwsim tests 3 times on fail
This commit is contained in:
22
.github/workflows/hostap.yml
vendored
22
.github/workflows/hostap.yml
vendored
@ -189,12 +189,24 @@ jobs:
|
||||
id: testing
|
||||
working-directory: hostap/tests/hwsim/
|
||||
run: |
|
||||
# Run tests in increments of 100 to cut down on the uploaded log size.
|
||||
while mapfile -t -n 100 ary && ((${#ary[@]})); do
|
||||
# Run tests in increments of 50 to cut down on the uploaded log size.
|
||||
while mapfile -t -n 50 ary && ((${#ary[@]})); do
|
||||
TESTS=$(printf '%s\n' "${ary[@]}" | tr '\n' ' ')
|
||||
sudo ./start.sh
|
||||
sudo ./run-tests.py ${{ env.hostap_debug_flags }} --split ${{ matrix.server }}/5 $TESTS
|
||||
sudo ./stop.sh
|
||||
# Retry up to three times
|
||||
for i in {1..3}; do
|
||||
HWSIM_RES=0
|
||||
# Logs can grow quickly especially in debug mode
|
||||
sudo rm -rf logs
|
||||
sudo ./start.sh
|
||||
sudo ./run-tests.py ${{ env.hostap_debug_flags }} --split ${{ matrix.server }}/5 $TESTS || HWSIM_RES=$?
|
||||
sudo ./stop.sh
|
||||
if [ "$HWSIM_RES" -eq "0" ]; then
|
||||
break
|
||||
fi
|
||||
done
|
||||
if [ "$HWSIM_RES" -ne "0" ]; then
|
||||
exit $HWSIM_RES
|
||||
fi
|
||||
done < $GITHUB_WORKSPACE/wolfssl/.github/workflows/hostap-files/configs/${{ matrix.config.hostap_ref }}/tests
|
||||
|
||||
- name: Change failure log permissions
|
||||
|
Reference in New Issue
Block a user