-
Notifications
You must be signed in to change notification settings - Fork 355
124 lines (111 loc) · 3.87 KB
/
tests-daily.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
# ======================================
# WARNING!
# THIS FILE IS GENERATED FROM A TEMPLATE
# DO NOT EDIT THIS FILE MANUALLY!
# ======================================
# The template is located in: tests-daily.yml.j2
# Run unit tests daily.
#
# This is different from container rebuilds, where the tests "gate" the new version. The last
# container is used, always. That means, failures for this workflow signal breakages that are
# unrelated to the actual container builds.
#
# This should help as an additional data source to diagnose issues when things "randomly fail
# everywhere". Tests running here are not affected by any changes. In all other cases, these tests
# run after a change:
# - code changes on PRs
# - after container rebuilds
# - after merges
#
# Ideally, these tests run on the same hashes as the merge tests, and so help detect which
# differences actually matter for the breakage.
#
# Warning: This differs from the pull request tests, both steps and matrix. Don't copypaste.
name: Run validation tests daily
on:
# 2 AM
schedule:
- cron: 0 2 * * *
workflow_dispatch:
permissions:
contents: read
jobs:
unit-tests:
runs-on: ubuntu-22.04
timeout-minutes: 30
# Don't run scheduled workflows on forks.
if: github.event_name != 'schedule' || github.repository == 'rhinstaller/anaconda'
strategy:
fail-fast: false
matrix:
release: ['master', 'rhel-9', 'rhel-10']
include:
- release: 'master'
target_branch: 'master'
ci_tag: 'master'
## add to release: [...] also eln if re-enabled by uncommenting the below
#- release: 'eln'
# target_branch: 'master'
# ci_tag: 'eln'
# build-args: '--build-arg=image=quay.io/fedoraci/fedora:eln-x86_64'
- release: 'rhel-9'
target_branch: 'rhel-9'
ci_tag: 'rhel-9'
- release: 'rhel-10'
target_branch: 'rhel-10'
ci_tag: 'rhel-10'
env:
CI_TAG: '${{ matrix.ci_tag }}'
# Always avoid using cache because cache is not correctly invalidated.
CONTAINER_BUILD_ARGS: '--no-cache ${{ matrix.build-args }}'
steps:
- name: Clone repository
uses: actions/checkout@v4
with:
ref: ${{ matrix.target_branch }}
- name: Run tests in anaconda-ci container
run: |
# put the log in the output, where it's easy to read and link to
make -f Makefile.am container-ci || { cat test-logs/test-suite.log; exit 1; }
- name: Upload test and coverage logs
if: always()
uses: actions/upload-artifact@v4
with:
name: 'logs (${{ matrix.ci_tag }})'
path: test-logs/*
rpm-tests:
runs-on: ubuntu-22.04
timeout-minutes: 30
# Don't run scheduled workflows on forks.
if: github.event_name != 'schedule' || github.repository == 'rhinstaller/anaconda'
strategy:
fail-fast: false
matrix:
release: ['master', 'rhel-9', 'rhel-10']
include:
- release: 'master'
target_branch: 'master'
ci_tag: 'master'
- release: 'rhel-9'
target_branch: 'rhel-9'
ci_tag: 'rhel-9'
- release: 'rhel-10'
target_branch: 'rhel-10'
ci_tag: 'rhel-10'
env:
CI_TAG: '${{ matrix.ci_tag }}'
# Always avoid using cache because cache is not correctly invalidated.
CONTAINER_BUILD_ARGS: '--no-cache ${{ matrix.build-args }}'
steps:
- name: Clone repository
uses: actions/checkout@v4
with:
ref: ${{ matrix.target_branch }}
- name: Run RPM tests in container
run: make -f Makefile.am container-rpm-test
- name: Upload test logs
if: always()
uses: actions/upload-artifact@v4
with:
name: 'logs-rpm-test (${{ matrix.ci_tag }})'
path: test-logs/*