chore: add testing packages

This commit is contained in:
Ilia Mashkov
2026-03-16 18:28:41 +03:00
parent fa3f461add
commit 6bfcc4db24
4 changed files with 1387 additions and 9 deletions

32
vitest.config.ts Normal file
View File

@@ -0,0 +1,32 @@
import { defineConfig } from "vitest/config";
import react from "@vitejs/plugin-react";
import path from "path";
export default defineConfig({
plugins: [
react({
babel: {
plugins: [["babel-plugin-react-compiler", {}]],
},
}),
],
resolve: {
alias: {
shared: path.resolve(__dirname, "src/shared"),
entities: path.resolve(__dirname, "src/entities"),
features: path.resolve(__dirname, "src/features"),
widgets: path.resolve(__dirname, "src/widgets"),
app: path.resolve(__dirname, "src/app"),
},
},
test: {
globals: true,
environment: "jsdom",
setupFiles: ["./src/shared/config/test/setup.ts"],
coverage: {
provider: "v8",
reporter: ["text", "json", "html"],
exclude: ["node_modules/", "src/test/"],
},
},
});