Skip to content

Commit 2962895

Browse files
committed
Add prettier to mvntest
1 parent 1401b20 commit 2962895

File tree

4 files changed

+11
-16
lines changed

4 files changed

+11
-16
lines changed

CONTRIBUTING.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,7 +100,7 @@ Code style will be enforced by GitHub pull request checks.
100100

101101
For frontend code we use [eslint](https://eslint.org) and [prettier](https://prettier.io/).
102102

103-
You can automatically fix issues with `npm run lint:fix`
103+
You can automatically fix issues with `npm run format && npm run eslint:fix`
104104

105105
For java code we use [spotless](https://github.com/diffplug/spotless).
106106

package.json

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,20 @@
55
"private": true,
66
"type": "module",
77
"scripts": {
8-
"mvnbuild": "npm run build",
9-
"mvntest": "eslint --format checkstyle --output-file target/eslint-warnings.xml; vitest run --reporter junit",
108
"build": "vite build --mode production",
119
"build:dev": "vite build --mode production --watch",
12-
"format:check": "prettier --check .",
1310
"format": "prettier --write .",
14-
"lint": "tsc && eslint && npm run format:check",
15-
"lint:fix": "eslint --fix && npm run format",
11+
"format:check": "prettier --check .",
12+
"tsc:check": "tsc",
13+
"eslint": "eslint",
14+
"eslint:fix": "eslint --fix",
15+
"lint": "npm run tsc:check && npm run eslint",
1616
"test": "vitest run",
17-
"test:dev": "vitest watch"
17+
"test:dev": "vitest watch",
18+
"eslint:mvn": "eslint --format checkstyle --output-file target/eslint-warnings.xml || ([ -n \"$JENKINS_URL\" ] && [ -f target/eslint-warnings.xml ])",
19+
"vitest:mvn": "vitest run --reporter default --reporter junit --outputFile \"$PWD/target/surefire-reports/vitest-junit.xml\" || ([ -n \"$JENKINS_URL\" ] && [ -f target/surefire-reports/vitest-junit.xml ])",
20+
"mvnbuild": "npm run build",
21+
"mvntest": "npm run format:check && npm run tsc:check && npm run eslint:mvn && npm run vitest:mvn"
1822
},
1923
"repository": {
2024
"type": "git",

pom.xml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,10 +38,6 @@
3838
<node.version>22.15.0</node.version>
3939
<npm.version>11.3.0</npm.version>
4040
<spotless.check.skip>false</spotless.check.skip>
41-
42-
<!-- Opt in to Jenkins handling eslint results -->
43-
<maven.test.failure.ignore>false</maven.test.failure.ignore>
44-
<frontend.testFailureIgnore>${maven.test.failure.ignore}</frontend.testFailureIgnore>
4541
</properties>
4642

4743
<dependencyManagement>

vitest.config.ts

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,10 @@
11
import { defineConfig } from "vitest/config";
2-
import path from "node:path";
32

43
export default defineConfig({
54
test: {
65
root: "src/main/frontend",
76
globals: true,
87
environment: "jsdom",
98
setupFiles: ["setupTests.ts"],
10-
outputFile: path.resolve(
11-
import.meta.dirname,
12-
"target/surefire-reports/vitest-junit.xml",
13-
),
149
},
1510
});

0 commit comments

Comments
 (0)