Commit 7740e05
committed
NP-790: Harden bundle smoke test and document commitOpts coupling
Addresses ts-node-reviewer findings on the previous commit
(4de84b0):
* `runChildAndCapture` now listens for `error` on the child so a
failed spawn (e.g. ENOENT on the node binary) folds the error into
the captured stderr and resolves immediately instead of hanging
until the SIGKILL timer fires. A `settled` guard protects against
the close/error race.
* The mock HTTP server's `listen` promise now attaches a one-shot
`error` handler so a failed bind (EADDRINUSE on a constrained CI
host, etc.) rejects with a useful message instead of letting the
test silently wedge until Vitest's test timeout.
* `src/action.ts` gains an explicit comment next to the preset pre-
resolution explaining that upstream `load-changelog-config.js`
never merges a plugin-supplied `commits` field, so `commitOpts`
always comes from angular when no `preset` / `config` is passed.
Harmless today (angular and conventionalcommits both default to
`{ ignore: undefined, merges: false }`) but worth flagging for
future upstream drift.
No behavioural change to the shipping bundle — `esbuild` strips
comments and the smoke test's runtime changes only affect error
paths that previously caused hangs, not the happy path. All 37
tests across 5 files still pass; lint, prettier, and typecheck
clean.
Made-with: Cursor1 parent 4de84b0 commit 7740e05
2 files changed
Lines changed: 47 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
216 | 216 | | |
217 | 217 | | |
218 | 218 | | |
| 219 | + | |
| 220 | + | |
| 221 | + | |
| 222 | + | |
| 223 | + | |
| 224 | + | |
| 225 | + | |
| 226 | + | |
219 | 227 | | |
220 | 228 | | |
221 | 229 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | | - | |
| 57 | + | |
| 58 | + | |
58 | 59 | | |
59 | 60 | | |
60 | 61 | | |
| |||
63 | 64 | | |
64 | 65 | | |
65 | 66 | | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
66 | 82 | | |
67 | 83 | | |
68 | 84 | | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
| 89 | + | |
| 90 | + | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
69 | 94 | | |
70 | 95 | | |
71 | 96 | | |
72 | 97 | | |
73 | 98 | | |
74 | | - | |
75 | | - | |
76 | | - | |
77 | | - | |
78 | | - | |
79 | | - | |
80 | | - | |
| 99 | + | |
81 | 100 | | |
82 | 101 | | |
83 | 102 | | |
| |||
209 | 228 | | |
210 | 229 | | |
211 | 230 | | |
212 | | - | |
213 | | - | |
| 231 | + | |
| 232 | + | |
| 233 | + | |
| 234 | + | |
| 235 | + | |
| 236 | + | |
| 237 | + | |
| 238 | + | |
| 239 | + | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
214 | 243 | | |
215 | 244 | | |
216 | 245 | | |
| |||
0 commit comments