|
30 | 30 | "@eslint/js": "^9.19.0",
|
31 | 31 | "@types/debug": "^4.1.7",
|
32 | 32 | "@types/estree": "^1.0.0",
|
33 |
| - "@types/mocha": "^9.0.0", |
34 | 33 | "@types/node": "^18.8.4",
|
35 | 34 | "@types/semver": "^7.3.12",
|
36 | 35 | "@typescript-eslint/eslint-plugin": "^8.22.0",
|
37 | 36 | "@typescript-eslint/parser": "^8.22.0",
|
| 37 | + "@vitest/coverage-v8": "^3.2.4", |
| 38 | + "@vitest/ui": "^3.2.4", |
38 | 39 | "chokidar": "^3.5.2",
|
39 | 40 | "cross-spawn": "^7.0.3",
|
40 | 41 | "dts-bundle": "^0.7.3",
|
|
47 | 48 | "eslint-plugin-unicorn": "^57.0.0",
|
48 | 49 | "fs-extra": "^10.0.0",
|
49 | 50 | "jsonc-eslint-parser": "^2.0.3",
|
50 |
| - "mocha": "^9.1.3", |
51 | 51 | "npm-run-all": "^4.1.5",
|
52 |
| - "nyc": "^15.1.0", |
53 |
| - "opener": "^1.5.2", |
54 | 52 | "prettier": "^3.4.2",
|
55 | 53 | "rimraf": "^3.0.2",
|
56 | 54 | "rollup": "^2.60.0",
|
|
59 | 57 | "rollup-plugin-sourcemaps": "^0.6.3",
|
60 | 58 | "ts-node": "^10.9.2",
|
61 | 59 | "typescript": "~5.7.3",
|
| 60 | + "vite": "^6.3.5", |
| 61 | + "vitest": "^3.2.4", |
62 | 62 | "wait-on": "^6.0.0",
|
63 | 63 | "warun": "^1.0.0"
|
64 | 64 | },
|
65 | 65 | "scripts": {
|
66 | 66 | "prebuild": "npm run -s clean",
|
67 | 67 | "build": "tsc --module es2015 && rollup -c -o index.js && dts-bundle --name vue-eslint-parser --main .temp/index.d.ts --out ../index.d.ts",
|
68 |
| - "clean": "rimraf .nyc_output .temp coverage index.*", |
69 |
| - "coverage": "opener ./coverage/lcov-report/index.html", |
| 68 | + "clean": "rimraf .temp index.*", |
| 69 | + "coverage": "vitest --coverage --ui", |
70 | 70 | "lint": "eslint src test package.json",
|
71 |
| - "pretest": "run-s build lint", |
72 |
| - "test": "npm run -s test:mocha", |
73 |
| - "test:mocha": "mocha --require ts-node/register \"test/*.js\" --reporter dot --timeout 60000", |
74 |
| - "test:cover": "nyc mocha \"test/*.js\" --reporter dot --timeout 60000", |
75 |
| - "test:debug": "mocha --require ts-node/register/transpile-only \"test/*.js\" --reporter dot --timeout 60000", |
| 71 | + "test": "vitest", |
| 72 | + "test:cover": "vitest --coverage", |
76 | 73 | "update-fixtures": "ts-node --transpile-only scripts/update-fixtures-ast.js && ts-node --transpile-only scripts/update-fixtures-document-fragment.js",
|
77 | 74 | "preversion": "npm test",
|
78 | 75 | "version": "npm run -s build",
|
|
81 | 78 | "watch": "run-p watch:*",
|
82 | 79 | "watch:tsc": "tsc --module es2015 --watch",
|
83 | 80 | "watch:rollup": "wait-on .temp/index.js && rollup -c -o index.js --watch",
|
84 |
| - "watch:test": "wait-on index.js && warun index.js \"test/*.js\" \"test/fixtures/ast/*/*.json\" \"test/fixtures/*\" --debounce 1000 --no-initial -- nyc mocha \"test/*.js\" --reporter dot --timeout 10000", |
85 |
| - "watch:update-ast": "wait-on index.js && warun index.js \"test/fixtures/ast/*/*.vue\" -- ts-node scripts/update-fixtures-ast.js", |
86 |
| - "watch:coverage-report": "wait-on coverage/lcov-report/index.html && opener coverage/lcov-report/index.html" |
| 81 | + "watch:update-ast": "wait-on index.js && warun index.js \"test/fixtures/ast/*/*.vue\" -- ts-node scripts/update-fixtures-ast.js" |
87 | 82 | },
|
88 | 83 | "repository": {
|
89 | 84 | "type": "git",
|
|
0 commit comments