Skip to content

Commit c05045f

Browse files
committed
ci: use tox-lsr 3.6.0; improve qemu test logging
tox-lsr 3.6.0 will guarantee order of qemu test execution, which should help make tests reproducible and help debug test failures. Improve qemu test logging - this will help debug the qemu test failures. Signed-off-by: Rich Megginson <[email protected]>
1 parent df0f5d7 commit c05045f

File tree

5 files changed

+24
-9
lines changed

5 files changed

+24
-9
lines changed

.github/workflows/ansible-lint.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ jobs:
3232
- name: Install tox, tox-lsr
3333
run: |
3434
set -euxo pipefail
35-
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.5.1"
35+
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.6.0"
3636
3737
- name: Convert role to collection format
3838
id: collection

.github/workflows/ansible-managed-var-comment.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
- name: Install tox, tox-lsr
3131
run: |
3232
set -euxo pipefail
33-
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.5.1"
33+
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.6.0"
3434
3535
- name: Run ansible-plugin-scan
3636
run: |

.github/workflows/ansible-test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
- name: Install tox, tox-lsr
3434
run: |
3535
set -euxo pipefail
36-
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.5.1"
36+
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.6.0"
3737
3838
- name: Convert role to collection format
3939
run: |

.github/workflows/python-unit-test.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ jobs:
6565
tox=tox
6666
virtualenv=virtualenv
6767
fi
68-
pip install "$tox" "$virtualenv" "git+https://github.com/linux-system-roles/tox-lsr@3.5.1"
68+
pip install "$tox" "$virtualenv" "git+https://github.com/linux-system-roles/tox-lsr@3.6.0"
6969
# If you have additional OS dependency packages e.g. libcairo2-dev
7070
# then put them in .github/config/ubuntu-requirements.txt, one
7171
# package per line.

.github/workflows/qemu-kvm-integration-tests.yml

Lines changed: 20 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -74,7 +74,7 @@ jobs:
7474
python3 -m pip install --upgrade pip
7575
sudo apt update
7676
sudo apt install -y --no-install-recommends git ansible-core genisoimage qemu-system-x86
77-
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.5.1"
77+
pip3 install "git+https://github.com/linux-system-roles/tox-lsr@3.6.0"
7878
7979
- name: Configure tox-lsr
8080
if: steps.check_platform.outputs.supported
@@ -109,14 +109,29 @@ jobs:
109109
echo "$f"
110110
done < batch.report
111111
112-
- name: Show test logs on failure
112+
- name: Upload test logs on failure
113+
if: failure()
114+
uses: actions/upload-artifact@v4
115+
with:
116+
name: "logs-${{ matrix.scenario.image }}-${{ matrix.scenario.env }}"
117+
path: |
118+
tests/*.log
119+
artifacts/default_provisioners.log
120+
artifacts/*.qcow2.*.log
121+
batch.txt
122+
batch.report
123+
retention-days: 30
124+
125+
- name: Show test log failures
113126
if: steps.check_platform.outputs.supported && failure()
114127
run: |
115128
set -euo pipefail
116129
for f in tests/*.log; do
117-
echo "::group::$(basename $f)"
118-
cat "$f"
119-
echo "::endgroup::"
130+
if FAIL=$(grep -B100 -A30 "fatal:" "$f"); then
131+
echo "::group::$(basename $f)"
132+
echo "$FAIL"
133+
echo "::endgroup::"
134+
fi
120135
done
121136
122137
- name: Set commit status as success with a description that platform is skipped

0 commit comments

Comments
 (0)