open-nomad/ui/tests/.eslintrc.js
Buck Doyle 29de8f4f76
Add component accessibility auditing and fixes (#8679)
This continues #8455 by adding accessibility audits to component integration
tests and fixing associated errors. It adds audits to existing tests rather than
adding separate ones to facilitate auditing the various permutations a
component’s rendering can go through.

It also adds linting to ensure audits happen in component tests. This
necessitated consolidating test files that were scattered.
2020-08-25 10:56:02 -05:00

46 lines
1 KiB
JavaScript

module.exports = {
globals: {
server: true,
selectChoose: true,
selectSearch: true,
removeMultipleOption: true,
clearSelected: true,
getCodeMirrorInstance: true,
},
env: {
embertest: true,
},
overrides: [
{
files: ['acceptance/**/*-test.js'],
plugins: ['ember-a11y-testing'],
rules: {
'ember-a11y-testing/a11y-audit-called': 'error',
},
settings: {
'ember-a11y-testing': {
auditModule: {
package: 'nomad-ui/tests/helpers/a11y-audit',
exportName: 'default',
},
},
},
},
{
files: ['integration/components/**/*-test.js'],
plugins: ['ember-a11y-testing'],
rules: {
'ember-a11y-testing/a11y-audit-called': 'error',
},
settings: {
'ember-a11y-testing': {
auditModule: {
package: 'nomad-ui/tests/helpers/a11y-audit',
exportName: 'componentA11yAudit',
},
},
},
},
],
};