@voxgig/sdkgen 1.4.0 → 1.4.1

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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@voxgig/sdkgen",
3
- "version": "1.4.0",
3
+ "version": "1.4.1",
4
4
  "main": "dist/sdkgen.js",
5
5
  "type": "commonjs",
6
6
  "engines": {
@@ -64,6 +64,13 @@ const Package = cmp(async function Package(props: any) {
64
64
  type: 'commonjs',
65
65
  types: `dist/${SdkName}SDK.d.ts`,
66
66
  scripts: {
67
+ // `test` and `test-coverage` run the COMPILED suite in dist-test/, which
68
+ // a fresh clone does not have — the glob then matches nothing and the
69
+ // run reports "tests 0, pass 0, fail 0" and exits 0. A green suite that
70
+ // asserted nothing is worse than a red one, so build first. npm runs a
71
+ // `pre<script>` automatically, which keeps the test commands readable
72
+ // and cannot be forgotten by a caller invoking `npm test` directly.
73
+ 'pretest': 'npm run build',
67
74
  'test': 'node --enable-source-maps --test-concurrency=1 --test \'dist-test/**/*.test.js\'',
68
75
  'test-some': 'node --enable-source-maps --experimental-test-isolation=none ' +
69
76
  '--test-name-pattern=\"$TEST_PATTERN\" --test \'dist-test/**/*.test.js\'',
@@ -76,6 +83,7 @@ const Package = cmp(async function Package(props: any) {
76
83
  // regressions. Thresholds are a conservative floor (well under a
77
84
  // healthy SDK's ~92% lines) so they hold across API shapes; raise them
78
85
  // for a stricter local policy.
86
+ 'pretest-coverage': 'npm run build',
79
87
  'test-coverage': 'node --test-concurrency=1 --experimental-test-coverage ' +
80
88
  '--test-coverage-exclude=\'**/dist-test/**\' ' +
81
89
  '--test-coverage-lines=85 --test-coverage-branches=68 --test-coverage-functions=88 ' +