Skip to content

Commit 2fbf3b4

Browse files
committed
chore: refactor to Vitest
1 parent 1266ff6 commit 2fbf3b4

File tree

10 files changed

+990
-383
lines changed

10 files changed

+990
-383
lines changed

package.json

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@
1010
"templating",
1111
"transpilation"
1212
],
13+
"type": "module",
1314
"repository": "https://github.com/rich-harris/magic-string",
1415
"license": "MIT",
1516
"author": "Rich Harris",
@@ -33,14 +34,15 @@
3334
"scripts": {
3435
"build": "rollup -c",
3536
"changelog": "conventional-changelog -p angular -i CHANGELOG.md -s",
36-
"format": "prettier --single-quote --print-width 100 --use-tabs --write src/*.js src/**/*.js",
37+
"format": "prettier --single-quote --print-width 100 --use-tabs --write {src,test}/*.js {src,test}/**/*.js",
3738
"lint": "eslint src test && publint",
3839
"lint:fix": "eslint src test --fix",
3940
"prepare": "npm run build",
4041
"prepublishOnly": "npm run lint && rm -rf dist && npm test",
4142
"release": "bumpp -x \"npm run changelog\" --all --commit --tag --push && npm publish",
4243
"pretest": "npm run build",
43-
"test": "mocha",
44+
"test": "vitest run",
45+
"test:dev": "vitest",
4446
"bench": "npm run build && node benchmark/index.mjs",
4547
"watch": "rollup -cw"
4648
},
@@ -51,12 +53,12 @@
5153
"bumpp": "^9.4.1",
5254
"conventional-changelog-cli": "^3.0.0",
5355
"eslint": "^8.57.0",
54-
"mocha": "^10.7.0",
5556
"prettier": "^3.3.3",
5657
"publint": "^0.2.9",
5758
"rollup": "^3.29.4",
5859
"source-map-js": "^1.2.0",
59-
"source-map-support": "^0.5.21"
60+
"source-map-support": "^0.5.21",
61+
"vitest": "^2.1.8"
6062
},
6163
"dependencies": {
6264
"@jridgewell/sourcemap-codec": "^1.5.0"

0 commit comments

Comments
 (0)