chore: harden release — green suite, lint 0, ANSI unification (INT-2271, INT-2260)#190
Merged
Conversation
…e (INT-2271)
The 2 failing service.test.ts tests were stale, not a regression: the provider-
override reapply lives inside the `if (config.autonomous?.enabled)` block (it
calls runnerInstance.switchProvider, which needs a runner), but the tests drove
it with a non-autonomous config — one spread `mockConfig.autonomous` (undefined
→ {}), the other asserted readProviderOverride on a plain boot.
- 'reapplies override on boot' now uses mockAutonomousConfig (+ adapter override).
- 'initialize all required modules' drops the autonomous-only readProviderOverride
assertion (the reapply is covered by the two override-specific tests).
- service.test.ts: 37/37 green.
Also harden the release pipeline now that the suite is green:
- package.json: postbuild `chmod +x dist/cli.js` — a clean `rm -rf dist && build`
otherwise drops the exec bit and the global CLI hits "permission denied".
- ci.yml: promote the test job to a hard gate (drop continue-on-error).
…, INT-2270)
Now that the suite is green, make lint meaningful and finish the status-color
consistency work so the hard CI/release gates hold.
Lint (36 warnings → 0):
- Remove unused imports / variables across 11 files (issues bridges, discordCore,
chatMemory, scanner's recursion-only param, cli.ts self-registering command
binding, several test files).
- Prefix intentionally-unused mock params with `_`; disable no-control-regex on
the ANSI-stripping regex; two endsWith() swaps in bsDetector.
ANSI unification (checkHandler.ts):
- Replace the file's hand-rolled always-on ANSI `c` map (~108 call sites) with the
shared NO_COLOR/TTY-safe helper from src/support/colors — `c.green('x')` +
`status.ok/err/warn/glyph` where a status glyph fits. Non-status badges keep
their glyph. Output is byte-identical under non-TTY, so substring tests hold.
Full suite now green: typecheck / build / lint (0 warnings) / test (1306 passed).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pre-0.14.0 hardening: the whole suite is green for the first time, so the CI/release hard gates are now meaningful.
Changes
service.test.tsfailures. Not a regression: the provider-override reapply lives inside theif (config.autonomous?.enabled)block (it callsrunnerInstance.switchProvider), but the tests drove it with a non-autonomous config. Fixed to usemockAutonomousConfig/ drop the autonomous-only assertion. service.test.ts 37/37.no-control-regexdisable, twoendsWith()swaps.checkHandler.ts(~108 sites) now uses the shared NO_COLOR/TTY-safec/statusfromsrc/support/colorsinstead of a hand-rolled always-on ANSI map. Output byte-identical under non-TTY.chmod +x dist/cli.js— a cleanrm -rf dist && buildotherwise drops the exec bit → global CLI "permission denied".continue-on-error), now that the suite is green.Verification
🤖 Generated with Claude Code