Skip to content

Commit acd1e7f

Browse files
committed
Pair the ATEX tests with the packit testing farm tests.
1 parent 2ec5d12 commit acd1e7f

File tree

1 file changed

+81
-2
lines changed

1 file changed

+81
-2
lines changed

.github/workflows/atex-test.yaml

Lines changed: 81 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@ jobs:
5858
output: |
5959
{"summary":"Running ATEX tests: Job: ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}","title":"ATEX Testing in Progress"}
6060
61+
# All tests aggregated per CentOS Stream version
6162
test:
6263
name: Test on CentOS Stream ${{ matrix.centos_stream_major }}
6364
runs-on: ubuntu-latest
@@ -93,16 +94,94 @@ jobs:
9394
dnf -y install python3-pip git rsync
9495
pip install fmf atex==0.11
9596
96-
- name: Run tests on Testing Farm
97+
- name: Run static checks
9798
env:
9899
TESTING_FARM_API_TOKEN: ${{ secrets.TESTING_FARM_API_TOKEN }}
99100
CS_MAJOR: ${{ matrix.centos_stream_major }}
100101
run: |
102+
# Explicitly specify static checks to run, excluding:
103+
# - /static-checks/html-links (fails frequently due to temporary website availability issues)
104+
# - /static-checks/diff (always fails, meant for manual review)
105+
# - /static-checks/nist-validation (datastream is often noncompliant by design, e.g. SCE checks)
106+
# Tests from: https://github.com/RHSecurityCompliance/contest/tree/main/static-checks
101107
python3 tests/run_tests_testingfarm.py \
102108
--contest-dir contest \
103109
--content-dir content-centos-stream${CS_MAJOR} \
104110
--plan "/plans/daily" \
105-
--tests "/hardening/host-os/oscap/stig" \
111+
--tests \
112+
"/static-checks/ansible" \
113+
"/static-checks/removed-rules" \
114+
"/static-checks/rpmbuild-ctest" \
115+
"/static-checks/rule-identifiers" \
116+
"/static-checks/unit-tests-metadata" \
117+
--compose "CentOS-Stream-${CS_MAJOR}" \
118+
--arch x86_64 \
119+
--os-major-version "${CS_MAJOR}" \
120+
--timeout ${{ env.TEST_TIMEOUT }}
121+
122+
- name: Run hardening tests
123+
env:
124+
TESTING_FARM_API_TOKEN: ${{ secrets.TESTING_FARM_API_TOKEN }}
125+
CS_MAJOR: ${{ matrix.centos_stream_major }}
126+
run: |
127+
# Build test list based on CentOS Stream version
128+
TESTS=(
129+
# Tests for all versions (8, 9, 10)
130+
"/hardening/host-os/ansible/anssi_bp28_high"
131+
"/hardening/host-os/ansible/cis"
132+
"/hardening/host-os/ansible/cis_server_l1"
133+
"/hardening/host-os/ansible/cis_workstation_l1"
134+
"/hardening/host-os/ansible/cis_workstation_l2"
135+
"/hardening/host-os/ansible/e8"
136+
"/hardening/host-os/ansible/hipaa"
137+
"/hardening/host-os/ansible/ism_o"
138+
"/hardening/host-os/ansible/ospp"
139+
"/hardening/host-os/ansible/pci-dss"
140+
"/hardening/host-os/ansible/stig"
141+
"/hardening/host-os/oscap/anssi_bp28_high"
142+
"/hardening/host-os/oscap/cis"
143+
"/hardening/host-os/oscap/cis_server_l1"
144+
"/hardening/host-os/oscap/cis_workstation_l1"
145+
"/hardening/host-os/oscap/cis_workstation_l2"
146+
"/hardening/host-os/oscap/e8"
147+
"/hardening/host-os/oscap/hipaa"
148+
"/hardening/host-os/oscap/ism_o"
149+
"/hardening/host-os/oscap/ospp"
150+
"/hardening/host-os/oscap/pci-dss"
151+
"/hardening/host-os/oscap/stig"
152+
)
153+
154+
# CS8 and CS9 only: cui
155+
if [[ "${CS_MAJOR}" == "8" || "${CS_MAJOR}" == "9" ]]; then
156+
TESTS+=(
157+
"/hardening/host-os/ansible/cui"
158+
"/hardening/host-os/oscap/cui"
159+
)
160+
fi
161+
162+
# CS9 only: bsi, ccn_advanced
163+
if [[ "${CS_MAJOR}" == "9" ]]; then
164+
TESTS+=(
165+
"/hardening/host-os/ansible/bsi"
166+
"/hardening/host-os/ansible/ccn_advanced"
167+
"/hardening/host-os/oscap/bsi"
168+
"/hardening/host-os/oscap/ccn_advanced"
169+
)
170+
fi
171+
172+
# CS10 only: ism_o_top_secret
173+
if [[ "${CS_MAJOR}" == "10" ]]; then
174+
TESTS+=(
175+
"/hardening/host-os/ansible/ism_o_top_secret"
176+
"/hardening/host-os/oscap/ism_o_top_secret"
177+
)
178+
fi
179+
180+
python3 tests/run_tests_testingfarm.py \
181+
--contest-dir contest \
182+
--content-dir content-centos-stream${CS_MAJOR} \
183+
--plan "/plans/daily" \
184+
--tests "${TESTS[@]}" \
106185
--compose "CentOS-Stream-${CS_MAJOR}" \
107186
--arch x86_64 \
108187
--os-major-version "${CS_MAJOR}" \

0 commit comments

Comments
 (0)