Skip to content

Commit 1bbbd2d

Browse files
committed
test: update tests
1 parent 2d32b62 commit 1bbbd2d

2 files changed

Lines changed: 20 additions & 1 deletion

File tree

test/nuxt/a11y.spec.ts

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ afterEach(() => {
5757
import {
5858
AppFooter,
5959
AppHeader,
60+
BaseCard,
6061
UserAvatar,
6162
BuildEnvironment,
6263
CallToAction,
@@ -211,6 +212,25 @@ describe('component accessibility audits', () => {
211212
})
212213
})
213214

215+
describe('BaseCard', () => {
216+
it('should have no accessibility violations', async () => {
217+
const component = await mountSuspended(BaseCard, {
218+
slots: { default: '<p>Card content</p>' },
219+
})
220+
const results = await runAxe(component)
221+
expect(results.violations).toEqual([])
222+
})
223+
224+
it('should have no accessibility violations with exact match highlight', async () => {
225+
const component = await mountSuspended(BaseCard, {
226+
props: { isExactMatch: true },
227+
slots: { default: '<p>Exact match content</p>' },
228+
})
229+
const results = await runAxe(component)
230+
expect(results.violations).toEqual([])
231+
})
232+
})
233+
214234
describe('TooltipApp', () => {
215235
it('should have no accessibility violations', async () => {
216236
const component = await mountSuspended(TooltipApp, {

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

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,6 @@ const SKIPPED_COMPONENTS: Record<string, string> = {
4141
'Package/WeeklyDownloadStats.vue':
4242
'Uses vue-data-ui VueUiSparkline - has DOM measurement issues in test environment',
4343
'UserCombobox.vue': 'Unused component - intended for future admin features',
44-
'Card.vue': 'Already covered indirectly via other component tests',
4544
'SkeletonBlock.vue': 'Already covered indirectly via other component tests',
4645
'SkeletonInline.vue': 'Already covered indirectly via other component tests',
4746
}

0 commit comments

Comments
 (0)