Retry better, including a fail...

This commit is contained in:
Robert de Bock 2020-07-07 11:49:29 +02:00
parent 17a073a830
commit 52e7261736
2 changed files with 4 additions and 4 deletions

View File

@ -21,7 +21,7 @@ jobs:
path: {% raw %}"${{ github.repository }}"{% endraw %} path: {% raw %}"${{ github.repository }}"{% endraw %}
- name: molecule - name: molecule
uses: robertdebock/molecule-action@2.5.0 uses: robertdebock/molecule-action@2.5.1
with: with:
command: lint command: lint
test: test:
@ -51,7 +51,7 @@ jobs:
- name: parse apparmor for mysql - name: parse apparmor for mysql
run: sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld run: sudo apparmor_parser -R /etc/apparmor.d/usr.sbin.mysqld
- name: molecule - name: molecule
uses: robertdebock/molecule-action@2.5.0 uses: robertdebock/molecule-action@2.5.1
with: with:
image: {% raw %}${{ matrix.config.image }}{% endraw %} image: {% raw %}${{ matrix.config.image }}{% endraw %}

View File

@ -29,9 +29,9 @@ install:
script: script:
{% if tox_parallel is defined and tox_parallel %} {% if tox_parallel is defined and tox_parallel %}
- n=0 ; until [ "$n" = 3 ] ; do tox --parallel all && break ; n=$((n+1)) ; done - function retry { counter=0 ; until "$@" ; do exit=$? ; counter=$(($counter + 1)) ; if [ $counter -ge 3 ] ; then return $exit ; fi ; done ; return 0; } ; retry tox --parallel all
{% else %} {% else %}
- n=0 ; until [ "$n" = 3 ] ; do tox && break ; n=$((n+1)) ; done - function retry { counter=0 ; until "$@" ; do exit=$? ; counter=$(($counter + 1)) ; if [ $counter -ge 3 ] ; then return $exit ; fi ; done ; return 0; } ; retry tox
{% endif %} {% endif %}
notifications: notifications: