diff --git a/vite.config.ts b/vite.config.ts index e89277e5..f30f147c 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -1,4 +1,3 @@ -/// import { defineConfig } from "vite"; import react from "@vitejs/plugin-react"; import svgr from "vite-plugin-svgr"; @@ -14,20 +13,6 @@ export const appConfig = { uploadToken: process.env.CODECOV_TOKEN, }), ], - test: { - environment: "happy-dom", - setupFiles: ["./src/setupTests.tsx"], - coverage: { - exclude: ["styled-system/**"], - thresholds: { - statements: 90, - branches: 85, - functions: 95, - lines: 90, - }, - reporter: ["text", "text-summary", "lcov"], - }, - }, optimizeDeps: { exclude: ["node_modules/.cache/storybook"], }, diff --git a/vite.lib.config.ts b/vite.lib.config.ts index e916aca0..f339164f 100644 --- a/vite.lib.config.ts +++ b/vite.lib.config.ts @@ -1,4 +1,3 @@ -/// import { readdirSync } from "fs"; import { resolve } from "path"; import { defineConfig } from "vite"; diff --git a/vitest.config.ts b/vitest.config.ts new file mode 100644 index 00000000..ba24110a --- /dev/null +++ b/vitest.config.ts @@ -0,0 +1,21 @@ +import { defineConfig } from "vitest/config"; +import react from "@vitejs/plugin-react"; +import svgr from "vite-plugin-svgr"; + +export default defineConfig({ + plugins: [react(), svgr()], + test: { + environment: "happy-dom", + setupFiles: ["./src/setupTests.tsx"], + coverage: { + exclude: ["styled-system/**"], + thresholds: { + statements: 90, + branches: 85, + functions: 95, + lines: 90, + }, + reporter: ["text", "text-summary", "lcov"], + }, + }, +});