Skip to content

Commit

Permalink
Update accessibility-scan.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
jeetgarg authored Jan 28, 2025
1 parent c054170 commit 6902f41
Showing 1 changed file with 13 additions and 5 deletions.
18 changes: 13 additions & 5 deletions .github/workflows/accessibility-scan.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,8 +18,8 @@ jobs:
- name: Install dependencies
run: npm install

- name: Install axe-core and http-server
run: npm install -g axe-core http-server
- name: Install axe-cli and http-server
run: npm install -g axe-cli http-server

- name: Start local server
run: |
Expand All @@ -28,9 +28,8 @@ jobs:
- name: Create axe-reports directory
run: mkdir -p ./axe-reports

- name: Run axe-core accessibility scan
run: |
npx axe-core http://localhost:8080 --output html --output-path ./axe-reports/accessibility-report.html
- name: Run axe-cli accessibility scan
run: npx axe-cli http://localhost:8080 --output html --output-path ./axe-reports/accessibility-report.html

- name: Verify report creation
run: |
Expand All @@ -42,3 +41,12 @@ jobs:
with:
name: axe-report
path: ./axe-reports/accessibility-report.html

ls -la ./axe-reports/
cat ./axe-reports/accessibility-report.html || echo "Report not created"

- name: Upload axe-core report
uses: actions/upload-artifact@v3
with:
name: axe-report
path: ./axe-reports/accessibility-report.html

0 comments on commit 6902f41

Please sign in to comment.