mirror of
https://github.com/nuxt/ui.git
synced 2026-09-14 19:51:10 +08:00
f2d73e5bee
Co-authored-by: Jakub <jakub.michalek@freelo.io> Co-authored-by: Benjamin Canac <canacb1@gmail.com>
26 lines
551 B
TypeScript
26 lines
551 B
TypeScript
import * as matchers from 'vitest-axe/matchers'
|
|
|
|
import { expect } from 'vitest'
|
|
import { configureAxe } from 'vitest-axe'
|
|
|
|
// @ts-expect-error incomplete implementation
|
|
window.IntersectionObserver = class IntersectionObserver {
|
|
// eslint-disable-next-line
|
|
constructor() {}
|
|
observe() {}
|
|
unobserve() {}
|
|
disconnect() {}
|
|
}
|
|
|
|
configureAxe({
|
|
globalOptions: {
|
|
rules: [{
|
|
// Disable region rule as it doesn't work well with components rendered in isolation.
|
|
id: 'region',
|
|
enabled: false
|
|
}]
|
|
}
|
|
})
|
|
|
|
expect.extend(matchers)
|