spawn/packages/cli/src
A 994a512115
test: Remove duplicate and theatrical tests (#3089)
* test: remove duplicate and theatrical tests

- update-check.test.ts: fix 3 tests using stale hardcoded version '0.2.3'
  (older than current 0.29.1) to use `pkg.version` so 'should not update
  when up to date' actually tests the current-version path correctly
- run-path-credential-display.test.ts: strengthen weak `toBeDefined()`
  assertion on digitalocean hint to `toContain('Simple cloud hosting')`,
  making it verify the actual fallback hint content

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* test: replace theatrical no-assert tests with real assertions in recursive-spawn

Two tests in recursive-spawn.test.ts captured console.log output into a
logs array but never asserted against it. Both ended with a comment like
"should not throw" — meaning they only proved the function didn't crash,
not that it produced the right output.

- "shows empty message when no history": now spies on p.log.info and
  asserts cmdTree() emits "No spawn history found."
- "shows flat message when no parent-child relationships": now asserts
  cmdTree() emits "no parent-child relationships" via p.log.info.

expect() call count: 4831 to 4834 (+3 real assertions added).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>

* test: consolidate redundant describe block in cmd-fix-cov.test.ts

The file had two separate describe blocks with identical beforeEach/afterEach
boilerplate. The second block ("fixSpawn connection edge cases") contained only
one test ("shows success when fix script succeeds") and could be merged directly
into the first block ("fixSpawn (additional coverage)") without any loss of
coverage or setup fidelity.

Removes 23 lines of duplicated boilerplate. Test count unchanged (6 tests).

---------

Co-authored-by: spawn-qa-bot <qa@openrouter.ai>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-30 13:59:55 -07:00
..
__tests__ test: Remove duplicate and theatrical tests (#3089) 2026-03-30 13:59:55 -07:00
aws fix(security): expand $HOME before path validation in downloadFile (#3080) 2026-03-30 19:56:05 +00:00
commands fix(spawn-fix): load API keys via config file, not just process.env (#3095) 2026-03-31 03:03:47 +07:00
digitalocean fix(security): expand $HOME before path validation in downloadFile (#3080) 2026-03-30 19:56:05 +00:00
gcp fix(security): expand $HOME before path validation in downloadFile (#3080) 2026-03-30 19:56:05 +00:00
hetzner fix(security): expand $HOME before path validation in downloadFile (#3080) 2026-03-30 19:56:05 +00:00
local fix: scope local warning to openclaw-only + improve spawn skill docs (#3074) 2026-03-27 22:54:24 -07:00
shared fix(spawn-fix): load API keys via config file, not just process.env (#3095) 2026-03-31 03:03:47 +07:00
sprite fix(security): expand $HOME before path validation in downloadFile (#3080) 2026-03-30 19:56:05 +00:00
flags.ts fix: add --yes/-y to KNOWN_FLAGS so spawn delete --name <name> --yes works (#3024) 2026-03-27 02:54:33 +07:00
guidance-data.ts refactor: remove dead exports only used within their own files (#2431) 2026-03-10 08:51:15 -04:00
history.ts feat: recursive spawn (--beta recursive) (#2978) 2026-03-25 10:42:09 -07:00
index.ts feat: recursive spawn tree passback (#3023) 2026-03-26 15:21:50 -07:00
manifest.ts fix: temporarily disable Cursor CLI agent (#3055) 2026-03-27 02:08:04 -07:00
picker.ts refactor: remove dead exported types from picker.ts and spawn-config.ts (#2553) 2026-03-12 21:43:05 -04:00
security.ts fix(security): resolve symlinks in prompt file validation to prevent bypass (#2744) 2026-03-17 22:21:11 -07:00
unicode-detect.ts feat: Bun workspace monorepo — packages/cli + packages/shared (#1853) 2026-02-23 22:07:05 -08:00
update-check.ts fix(update-check): redirect install script stdout to stderr in --output json mode (#2919) 2026-03-24 03:18:50 +07:00