Skip to content

Commit cf7f92c

Browse files
committed
CCM-12666: add wcag2aaa standard which includes the heading order violation rule.
1 parent 7689797 commit cf7f92c

File tree

2 files changed

+11
-2
lines changed

2 files changed

+11
-2
lines changed

tests/test-team/config/accessibility/accessibility.config.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ export default defineConfig({
4545
],
4646
/* Run your local dev server before starting the tests */
4747
webServer: {
48-
timeout: 4 * 60 * 1000, // 2 minutes
48+
timeout: 4 * 60 * 1000, // 4 minutes
4949
command: buildCommand,
5050
cwd: path.resolve(__dirname, '../../../..'),
5151
url: 'http://localhost:3000/templates/create-and-submit-templates',

tests/test-team/fixtures/accessibility-analyze.ts

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,17 @@ type AccessibilityFixture = {
1515
analyze: Analyze;
1616
};
1717

18+
const DISABLED_RULES = [
19+
/* We don't have control over NHS colours.
20+
* Axe decides the page is 5.75 ratio and wcag2aaa expects 7:1
21+
*/
22+
'color-contrast-enhanced',
23+
];
24+
1825
const makeAxeBuilder = (page: Page) =>
19-
new AxeBuilder({ page }).withTags(['wcag2a', 'wcag2aa']);
26+
new AxeBuilder({ page })
27+
.withTags(['wcag2a', 'wcag2aa', 'wcag2aaa'])
28+
.disableRules(DISABLED_RULES);
2029

2130
export const test = base.extend<AccessibilityFixture>({
2231
analyze: async ({ baseURL, page }, use) => {

0 commit comments

Comments
 (0)