Skip to content

Commit 7ef7394

Browse files
try with empty BASE_URL
1 parent 70c9c89 commit 7ef7394

1 file changed

Lines changed: 6 additions & 23 deletions

File tree

.github/workflows/a11y.yml

Lines changed: 6 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -43,42 +43,25 @@ jobs:
4343
- name: Get Matching Chrome version
4444
run: npx browser-driver-manager install chrome
4545

46-
# # DEBUGGING
47-
# - name: Start Server
48-
# run: |
49-
# # Start server in background
50-
# npx http-server ./_build/html -p 8080 -s &
51-
# sleep 5
52-
53-
# # DEBUGGING
54-
# - name: Debug - Curl Root Index
55-
# run: curl -v http://localhost:8080/index.html
56-
57-
# # DEBUGGING
58-
# - name: Debug - Curl Chapter Index
59-
# run: curl -v http://localhost:8080/chapters/01/what-is-data-science/index.html
60-
6146
# 3. Serve, Discover URLs, and Run Axe
6247
- name: Run Axe Checks
6348
run: |
64-
# A. Start a local server in the background
49+
# B. Start a local server in the background
6550
npx http-server ./_build/html -p 8080 -s &
66-
sleep 5
51+
npx wait-on http://localhost:8080/
6752
68-
# B. Generate the URL list from the actual build artifacts
69-
cd _build/html
70-
URLS=$(find . -name "*.html" -not -path "*/build/*" | sed 's|^\./||' | sed 's|^|http://localhost:8080/|' | tr '\n' ' ')
53+
# C. Generate the URL list from the actual build artifacts
54+
URLS=$(find ./_build/html -name "*.html" -not -path "*/build/*" | sed "s|./_build/html/|http://localhost:8080/|" | tr '\n' ' ')
7155
72-
# C. Run Axe CLI on the discovered URLs
56+
# D. Run Axe CLI on the discovered URLs
7357
axe $URLS \
7458
--tags wcag2a,wcag2aa,wcag21a,wcag21aa \
7559
--save axe-report.json \
76-
--post-get-pause 3000 \
7760
--exit
7861
7962
- name: Upload Accessibility Report
8063
if: always()
8164
uses: actions/upload-artifact@v4
8265
with:
8366
name: axe-report
84-
path: _build/html/axe-report.json
67+
path: axe-report.json

0 commit comments

Comments
 (0)