Skip to content

Commit

Permalink
chore: setup vitest-sonar-reporter
Browse files Browse the repository at this point in the history
  • Loading branch information
marcellmueller committed Dec 2, 2024
1 parent 0915673 commit 227dbc8
Show file tree
Hide file tree
Showing 3 changed files with 20 additions and 2 deletions.
16 changes: 15 additions & 1 deletion backend/package-lock.json

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

3 changes: 2 additions & 1 deletion backend/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,8 @@
"tsconfig-paths": "^4.2.0",
"typescript": "^5.2.2",
"unplugin-swc": "^1.5.1",
"vitest": "^2.1.8"
"vitest": "^2.1.8",
"vitest-sonar-reporter": "^2.0.0"
},
"lint-staged": {
"*.{js,ts}": "./node_modules/.bin/eslint --cache --fix"
Expand Down
3 changes: 3 additions & 0 deletions backend/vitest.config.mts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,9 @@ export default defineConfig({
provider: "v8",
reporter: ["text-summary", "text", "json", "html"],
},
reporters: process.env.GITHUB_ACTIONS
? [["vitest-sonar-reporter", { outputFile: "test-report.xml" }]]
: [],
},
plugins: [swc.vite()],
});

0 comments on commit 227dbc8

Please sign in to comment.