mirror of
https://github.com/toeverything/AFFiNE.git
synced 2026-09-07 01:09:54 +08:00
chore(electron): config vitest swc (#6282)
This commit is contained in:
@@ -1,11 +1,13 @@
|
||||
import { resolve } from 'node:path';
|
||||
import { fileURLToPath } from 'node:url';
|
||||
|
||||
import react from '@vitejs/plugin-react-swc';
|
||||
import { defineConfig } from 'vitest/config';
|
||||
|
||||
const rootDir = fileURLToPath(new URL('../../..', import.meta.url));
|
||||
|
||||
export default defineConfig({
|
||||
plugins: [react()],
|
||||
resolve: {
|
||||
alias: {
|
||||
// prevent tests using two different sources of yjs
|
||||
@@ -15,6 +17,7 @@ export default defineConfig({
|
||||
},
|
||||
|
||||
test: {
|
||||
setupFiles: [resolve(rootDir, './scripts/setup/global.ts')],
|
||||
include: ['./test/**/*.spec.ts'],
|
||||
testTimeout: 5000,
|
||||
poolOptions: {
|
||||
|
||||
Reference in New Issue
Block a user