Lighthouse: execution de pa11y pour compléter l'audit d'accessibilité

This commit is contained in:
2019-12-26 12:10:23 +01:00
parent 4fe6feb1a1
commit 19884e6719
4 changed files with 45 additions and 18 deletions

View File

@ -1,6 +1,9 @@
#!/bin/sh
set -x
envtpl -o config.js /home/lighthouse/config.js.tmpl
envtpl -o patty.json /home/lighthouse/patty.json.tmpl
mkdir -p reports
rm -f reports/*
@ -14,4 +17,12 @@ lighthouse \
--output json --output html \
--output-path=lighthouse \
-- \
"$LIGHTHOUSE_URL"
"$LIGHTHOUSE_URL"
export PUPPETEER_EXECUTABLE_PATH=$(which chromium-browser)
pa11y --reporter html \
--config ../patty.json \
--include-warnings \
--include-notices \
"$LIGHTHOUSE_URL" > pa11y.report.html || exit 0