feat(frontend): Add formSnapshotComparison test, add test setup
This commit is contained in:
@@ -4,18 +4,32 @@ import { defineVitestProject } from '@nuxt/test-utils/config'
|
||||
export default defineConfig({
|
||||
test: {
|
||||
projects: [
|
||||
{
|
||||
test: {
|
||||
name: 'unit',
|
||||
include: ['test/{e2e,unit}/*.{test,spec}.ts'],
|
||||
environment: 'node'
|
||||
}
|
||||
},
|
||||
await defineVitestProject({
|
||||
test: {
|
||||
name: 'nuxt',
|
||||
include: ['test/nuxt/*.{test,spec}.ts'],
|
||||
environment: 'nuxt'
|
||||
name: 'unit',
|
||||
include: ['test/unit/**/*.{test,spec}.ts'],
|
||||
environment: 'nuxt',
|
||||
environmentOptions: {
|
||||
nuxt: {
|
||||
domEnvironment: 'happy-dom'
|
||||
}
|
||||
}
|
||||
}
|
||||
}),
|
||||
await defineVitestProject({
|
||||
test: {
|
||||
name: 'integration',
|
||||
include: ['test/integration/**/*.{test,spec}.ts'],
|
||||
environment: 'nuxt',
|
||||
environmentOptions: {
|
||||
nuxt: {
|
||||
domEnvironment: 'happy-dom',
|
||||
mock: {
|
||||
intersectionObserver: true,
|
||||
indexedDb: true
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
]
|
||||
|
||||
Reference in New Issue
Block a user