Skip to content

Commit

Permalink
test(slash): fix vitest coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
MartinWeb authored and JLou committed Jan 24, 2025
1 parent 06de86f commit 34d27e3
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions slash/react/vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3,17 +3,32 @@
/// <reference types="vite/client" />

import react from "@vitejs/plugin-react";
import { defineProject } from "vitest/config";
import { defineConfig } from "vitest/config";

// https://vitejs.dev/config/
// eslint-disable-next-line import/no-default-export
export default defineProject({
export default defineConfig({
plugins: [react()],
test: {
globals: true,
environment: "jsdom",
setupFiles: "./vitest.setup.ts",
name: "slash",
css: true,
coverage: {
reporter: ["text", "lcov", "html"],
include: ["src/**/*.{js,mjs,cjs,ts,mts,cts,jsx,tsx}"],
exclude: [
"**/*.stories.ts?(x)",
"**/storybook-static/*",
"**/vitest.setup.ts",
"**/.storybook/",
"**/coverage/",
"**/dist/*",
"**/index.ts",
"**/__tests__/**",
"**/*.d.ts",
],
},
},
});

0 comments on commit 34d27e3

Please sign in to comment.