Skip to content

Commit f8b32d4

Browse files
committed
adding a11y test for changelog card.
excludes changelog releases due to needing api calls
1 parent 8d22cf2 commit f8b32d4

File tree

2 files changed

+19
-0
lines changed

2 files changed

+19
-0
lines changed

test/nuxt/a11y.spec.ts

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,7 @@ import {
119119
ButtonBase,
120120
LinkBase,
121121
CallToAction,
122+
ChangelogCard,
122123
CodeDirectoryListing,
123124
CodeFileTree,
124125
CodeMobileTreeDrawer,
@@ -1894,6 +1895,23 @@ describe('component accessibility audits', () => {
18941895
})
18951896
})
18961897

1898+
describe('Changelog', () => {
1899+
it('should have no accessibility violations', async () => {
1900+
const component = await mountSuspended(ChangelogCard, {
1901+
props: {
1902+
release: {
1903+
html: '<p>test a11y</p>',
1904+
id: 'a11y',
1905+
title: '1.0.0',
1906+
publishedAt: '2026-02-11 10:00:00.000Z',
1907+
},
1908+
},
1909+
})
1910+
const results = await runAxe(component)
1911+
expect(results.violations).toEqual([])
1912+
})
1913+
})
1914+
18971915
describe('CollapsibleSection', () => {
18981916
it('should have no accessibility violations', async () => {
18991917
const component = await mountSuspended(CollapsibleSection, {

test/unit/a11y-component-coverage.spec.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -46,6 +46,7 @@ const SKIPPED_COMPONENTS: Record<string, string> = {
4646
'SkeletonBlock.vue': 'Already covered indirectly via other component tests',
4747
'SkeletonInline.vue': 'Already covered indirectly via other component tests',
4848
'Button/Group.vue': "Wrapper component, tests wouldn't make much sense here",
49+
'Changelog/Releases.vue': 'Requires API calls',
4950
}
5051

5152
/**

0 commit comments

Comments
 (0)