thunderbench 1.0.5 → 1.0.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/dist/index.js +1 -1
  2. package/package.json +3 -3
package/dist/index.js CHANGED
@@ -8989,7 +8989,7 @@ var validateGroup = (group) => {
8989
8989
  if (group.connections <= 0) {
8990
8990
  throw new Error("连接数必须大于0");
8991
8991
  }
8992
- if (!group.duration) {
8992
+ if (group.duration === undefined || group.duration === null) {
8993
8993
  throw new Error(`测试组 "${group.name}" 必须指定 duration`);
8994
8994
  }
8995
8995
  if (group.duration <= 0) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "thunderbench",
3
- "version": "1.0.5",
3
+ "version": "1.0.7",
4
4
  "description": "ThunderBench - 高性能API性能测试工具核心引擎",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -23,9 +23,9 @@
23
23
  "scripts": {
24
24
  "build": "bun build src/index.ts --outdir ./dist --target node && tsc --project tsconfig.build.json",
25
25
  "dev": "bun --watch src/index.ts",
26
- "test": "vitest",
26
+ "test": "vitest --run",
27
27
  "prepublishOnly": "npm run build",
28
- "release": "bumpp"
28
+ "release": "bun run build && bun run test && bumpp && bun publish"
29
29
  },
30
30
  "keywords": [
31
31
  "performance",