Yet more ansible hackery: create results.yml
Gating tests are still failing. Actually, the BATS portion is all passing, it just seems to be the end part (infrastructure) that fails. Let's try creating a results.yml file. Signed-off-by: Ed Santiago <santiago@redhat.com>
This commit is contained in:
parent
869e93d116
commit
712ba62553
@ -46,18 +46,22 @@
|
||||
- summary
|
||||
|
||||
# Collect all the one-line PASS/FAIL results in one file, test.log
|
||||
# Write the same thing, in a different format, to results.yml
|
||||
# https://docs.fedoraproject.org/en-US/ci/standard-test-interface/
|
||||
- name: "{{ test.name }} | keep running tally of test results"
|
||||
local_action: shell cat "{{ artifacts }}/test.{{ test_name_oneword }}.summary.log" >>"{{ artifacts }}/test.log"
|
||||
local_action:
|
||||
module: shell
|
||||
cmd: |
|
||||
cd {{ artifacts }}
|
||||
cat "test.{{ test_name_oneword }}.summary.log" >>test.log
|
||||
|
||||
# ...then delete the oneliner file, to keep things clean.
|
||||
- name: "{{ test.name }} | clean up status file"
|
||||
local_action: file dest="{{ artifacts }}/test.{{ test_name_oneword }}.summary.log" state=absent
|
||||
status=$(awk '{print $1}' <test.{{ test_name_oneword }}.summary.log | tr A-Z a-z)
|
||||
echo "- test: {{ test.name }}" >>results.yml
|
||||
echo " result: $status" >>results.yml
|
||||
echo " logs: test.{{ test_name_oneword }}.bats.log" >>results.yml
|
||||
|
||||
# FIXME: do the same with results.yml:
|
||||
# - test: {{ test.name }}
|
||||
# result: pass or fail
|
||||
# logs:
|
||||
# - test.{{ test_name_oneword }}.bats.log
|
||||
# delete the oneliner file, to keep artifacts dir clean
|
||||
rm -f test.{{ test_name_oneword }}.summary.log
|
||||
|
||||
- name: "{{ test.name }} | remove remote logs and helpers"
|
||||
file:
|
||||
|
@ -17,9 +17,12 @@
|
||||
- name: remove stale log files
|
||||
local_action: shell rm -f {{ artifacts }}/test*.log
|
||||
|
||||
- name: clear test results
|
||||
- name: clear test results (test.log)
|
||||
local_action: command truncate --size=0 {{ artifacts }}/test.log
|
||||
|
||||
- name: clear test results (results.yml)
|
||||
local_action: copy content="requires:\n" dest={{ artifacts }}/results.yml
|
||||
|
||||
# These are the actual tests: set cgroups vN, then run root/rootless tests.
|
||||
- name: set cgroups and run podman tests
|
||||
include_tasks: test_podman_cgroups_vn.yml
|
||||
|
Loading…
Reference in New Issue
Block a user