agent-orchestrator/packages/cli/__tests__
Abu Talha 60e8c88100
fix(cli): make ao start URL cloning interactive to avoid SSH prompt hang (#1255)
* refactor(cli): unify interactive spawn helper

Consolidate interactive child-process spawning into runInteractiveCommand by adding an optional options bag (cwd/env and error context). This removes duplicate spawn logic and ensures consistent TTY-forwarding and error formatting for installer and clone flows.

Made-with: Cursor

* test(cli): mock interactive spawn in start URL clone tests

Update start URL clone tests to mock node:child_process spawn (stdio: inherit) instead of exec(), matching the interactive clone behavior and preventing hangs/timeouts.

Made-with: Cursor

* test(cli): standardize spawn mocks for start URL clone

Use an EventEmitter-based ChildProcess helper for spawn() in start command tests, matching existing repo patterns and reducing repetitive per-test mock return objects.

Made-with: Cursor

* test(cli): remove unknown cast from SessionManager mock

Add missing SessionManager methods to the start command test mock so we can type it as SessionManager directly without an unknown double-cast.

Made-with: Cursor

* test(cli): type spawn mock args in start tests

Replace unknown-typed spawn mock parameters with concrete cmd/args/options types to improve readability while keeping behavior unchanged.

Made-with: Cursor

* fix(test): remove duplicate mockSessionManager.restore key

Drop the duplicate restore mock introduced during main-branch merge conflict resolution.
2026-04-28 19:04:38 +05:30
..
commands fix(cli): make ao start URL cloning interactive to avoid SSH prompt hang (#1255) 2026-04-28 19:04:38 +05:30
lib fix(cli): avoid missing repo scripts on global installs (#1252) (#1277) 2026-04-26 16:47:49 +05:30
options refactor CLI version wiring for diff coverage 2026-04-02 17:34:19 +05:30
scripts fix(cli): avoid missing repo scripts on global installs (#1252) (#1277) 2026-04-26 16:47:49 +05:30
index.test.ts feat(cli): install-aware ao update, startup notifier, doctor version check (#1156) 2026-04-13 11:46:26 +05:30
program.test.ts refactor CLI version wiring for diff coverage 2026-04-02 17:34:19 +05:30