Skip to content

Commit

Permalink
feat: add coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
DennisSmuda committed Feb 16, 2025
1 parent 6dfc631 commit 641a12b
Show file tree
Hide file tree
Showing 4 changed files with 205 additions and 1 deletion.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@
.nitro
.cache
dist
coverage

# Node dependencies
node_modules
Expand Down
201 changes: 201 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
"build": "nuxt build",
"dev": "nuxt dev",
"test": "vitest",
"test:coverage": "vitest --coverage",
"test:e2e": "playwright test -c playwright.config.ts",
"generate": "nuxt generate",
"preview": "nuxt preview",
Expand All @@ -27,6 +28,7 @@
"@nuxt/test-utils": "^3.15.4",
"@playwright/test": "^1.50.1",
"@tailwindcss/typography": "^0.5.16",
"@vitest/coverage-v8": "^3.0.5",
"@vue/test-utils": "^2.4.6",
"eslint": "^9.20.1",
"happy-dom": "^16.8.1",
Expand Down
2 changes: 1 addition & 1 deletion vitest.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ export default defineVitestConfig({
exclude: ['**/e2e/**', '**/node_modules/**'],
coverage: {
// you can include other reporters, but 'json-summary' is required, json is recommended
reporter: ['text', 'json-summary', 'json'],
reporter: ['html', 'json-summary', 'json'],
// If you want a coverage reports even if your tests are failing, include the reportOnFailure option
reportOnFailure: true,
},
Expand Down

0 comments on commit 641a12b

Please sign in to comment.