Skip to content

Commit

Permalink
Writes pa11y-ci configuration file
Browse files Browse the repository at this point in the history
  • Loading branch information
jcarstairs-scottlogic committed Nov 29, 2023
1 parent 5acdb7f commit 6196216
Showing 1 changed file with 20 additions and 0 deletions.
20 changes: 20 additions & 0 deletions .pa11yci.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
const relativeUrls = require('./pa11y-ci-urls');

const chromiumBin = process.env.CHROMIUM_BIN;
if (!chromiumBin) {
throw new Error('CHROME_BIN environment variable is not set');
}

const baseUrl = 'http://localhost:4000';

module.exports = {
defaults: {
chromeLaunchConfig: {
executablePath: chromiumBin,
},
ignore: [
'WCAG2AA.Principle1.Guideline1_4.1_4_3.G18.Fail', // colour contrast, which is a known issue
],
},
urls: relativeUrls.map((url) => `${baseUrl}${url}`),
};

0 comments on commit 6196216

Please sign in to comment.