Skip to content

Commit b3cac2c

Browse files
committed
Enable webstandard job after fixed image
This reverts commit 90c3ab8.
1 parent cf4832b commit b3cac2c

File tree

2 files changed

+71
-3
lines changed

2 files changed

+71
-3
lines changed

.github/jobs/webstandard.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ ROLE="$2"
1414
cd /opt/domjudge/domserver
1515

1616
section_start "Setup pa11y"
17-
pa11y --version
17+
/home/domjudge/node_modules/.bin/pa11y --version
1818
section_end
1919

2020
section_start "Setup the test user"
@@ -143,8 +143,8 @@ else
143143
for file in $(find $URL -name "*.html")
144144
do
145145
section_start "$file"
146-
su domjudge -c "pa11y --config .github/jobs/pa11y_config.json $STAN -r json -T $ACCEPTEDERR $FLTR $file" | python3 -m json.tool
147-
ERR=$(su domjudge -c "pa11y --config .github/jobs/pa11y_config.json $STAN -r csv -T $ACCEPTEDERR $FLTR $file" | wc -l)
146+
su domjudge -c "/home/domjudge/node_modules/.bin/pa11y --config .github/jobs/pa11y_config.json $STAN -r json -T $ACCEPTEDERR $FLTR $file" | python3 -m json.tool
147+
ERR=$(su domjudge -c "/home/domjudge/node_modules/.bin/pa11y --config .github/jobs/pa11y_config.json $STAN -r csv -T $ACCEPTEDERR $FLTR $file" | wc -l)
148148
FOUNDERR=$((ERR+FOUNDERR-1)) # Remove header row
149149
section_end
150150
done

.github/workflows/webstandard.yml

Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
name: Webstandard (WCAG, W3C)
2+
on:
3+
push:
4+
branches:
5+
- main
6+
- '[0-9]+.[0-9]+'
7+
pull_request:
8+
branches:
9+
- main
10+
- '[0-9]+.[0-9]+'
11+
12+
jobs:
13+
standards:
14+
runs-on: ubuntu-latest
15+
container:
16+
image: domjudge/gitlabci:24.04
17+
services:
18+
sqlserver:
19+
image: mariadb
20+
ports:
21+
- 3306:3306
22+
env:
23+
MYSQL_ROOT_PASSWORD: root
24+
MYSQL_USER: domjudge
25+
MYSQL_PASSWORD: domjudge
26+
options: --health-cmd="healthcheck.sh --connect --innodb_initialized" --health-interval=10s --health-timeout=5s --health-retries=3
27+
strategy:
28+
matrix:
29+
role: [public, team, balloon, jury, admin]
30+
test: [w3cval, WCAG2A, WCAG2AA]
31+
db: [bare-install, install]
32+
releaseBranch:
33+
- ${{ contains(github.ref, 'main') }}
34+
exclude:
35+
- releaseBranch: false
36+
- role: jury
37+
test: WCAG2AA
38+
- role: jury
39+
test: WCAG2A
40+
- role: admin
41+
test: WCAG2AA
42+
- role: admin
43+
test: WCAG2A
44+
include:
45+
- role: public
46+
test: WCAG2AA
47+
db: install
48+
- role: public
49+
test: w3cval
50+
db: install
51+
- role: admin
52+
test: w3cval
53+
db: install
54+
steps:
55+
- uses: actions/checkout@v4
56+
- name: Install DOMjudge
57+
run: .github/jobs/baseinstall.sh ${{ matrix.role }}
58+
- name: Run webstandard tests (W3C, WCAG)
59+
run: .github/jobs/webstandard.sh ${{ matrix.test }} ${{ matrix.role }}
60+
- name: Upload all logs/artifacts
61+
if: ${{ !cancelled() }}
62+
uses: actions/upload-artifact@v4
63+
with:
64+
name: ${{ matrix.role }}-${{ matrix.test }}-${{ matrix.db }}-logs
65+
path: |
66+
/tmp/artifacts
67+
/var/log/nginx
68+
/opt/domjudge/domserver/webapp/var/log/*.log

0 commit comments

Comments
 (0)