Skip to content

Add the suites and journeys for the toolkit command and its control channel - #778

Open
adamsilverstein wants to merge 4 commits into
try/764-cli-for-ai-toolsfrom
add/764-toolkit-command-tests
Open

adamsilverstein wants to merge 4 commits into
try/764-cli-for-ai-toolsfrom
add/764-toolkit-command-tests

Conversation

@adamsilverstein

@adamsilverstein adamsilverstein commented Nov 13, 2026 •

Copy link
Copy Markdown
Member

The tests for #766, pulled out so the feature reads on its own. Second of three in the stack, and meant to merge right behind it.

Claude Code wrote these suites alongside the feature, and this is its summary of them:

Why

#766 adds the toolkit command and the control channel behind it (#764). With its suites it was about 4,400 lines in one pull request. These are the suites, split out so the feature can be read first and the proof of it second.

What changes

Tests only, no app code. Stacked on #766; #779 sits on top.

  • Five new unit files, one per new module: the socket and its refusals over a real socket in a temporary directory (control-channel.integration), how a site is named and what a read answers (control-sites), main's wait for the window (control-window), every action the window carries out against a stand-in for the page (control-requests), and the command's parsing, requests and output (cli).
  • Additions to three existing files: ipc-wiring pins the list of actions main hands the channel and proves each write is refused while the setting is off; node-shims covers the shim's arguments and setlocal on Windows; settings-view covers the command line the Tools tab shows.
  • Three journeys in tests/e2e/journeys/toolkit-command.spec.js that run the real command against the app: the listing with log and mail; the switch, then server start and stop; and a round on a ticket (link, build, check out and leave a pull request, unlink, update trunk).

That is 93 more unit tests than #766 has on its own.

How to test this

Platforms: any, and Windows matters for the named pipe, which CI covers. Nothing here has a surface of its own, so the commands are the test. From the repository root, on this branch:

  1. npm test. Expected: 2402 pass, 9 skipped, none failing.
  2. npm run build:once, then npm run test:e2e:hidden -- toolkit-command. Expected: the three journeys pass.

What must not have happened: no socket or bin/toolkit file left in a temporary directory by the wiring tests, which stub the listen. Step 2 on a stale renderer bundle fails for reasons that have nothing to do with the change, which is what the build in front of it is for.

Risks and limitations

  • No journey covers create, patch apply, install, --carry, or opening a closed app. Those are unit tested against a stand-in for the page only.
  • The journeys are skipped in CI while this is a draft, so they have only run on macOS, by hand.
  • The wiring tests wait for the channel by the clock, up to 10 seconds, after a version that counted turns failed on the Windows runner.

Related

Part of #764. Stacked on #766; #779 is next.


Review outcome (required — see AGENTS.md)

These files were in #766 when its three fresh-context passes ran, and the outcome is recorded there. Review findings about the tests themselves that were fixed: a log-bound test that proved nothing, and the turn-counting wait. Nothing in the files changed in the split; the tree at the top of the stack is identical to #766's head before it. Not re-reviewed since.

  • CodeRabbit: not requested yet

AI Use

Claude Code wrote these tests and this description. I will review and test.

🤖 Generated with Claude Code

https://claude.ai/code/session_018vwYjUEX6a9RXfZ6jHr6FN

…es with a request

The suites for #764, split from the pull request that adds the feature: the socket and its refusals, how a site is named, the waiting in main, each action the window carries out, the command's parsing and output, main's action list and its setting gate, the shim's arguments, the Tools tab's command line, and three journeys that drive the real app through the command.

Claude-Session: https://claude.ai/code/session_018vwYjUEX6a9RXfZ6jHr6FN
@coderabbitai

coderabbitai Bot commented Nov 13, 2026 •

Copy link
Copy Markdown

Important

Review skipped

Auto reviews are disabled on this repository. Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

Run configuration

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • Trigger review
  • Autofix · Keep fixing CodeRabbit findings and required CI, and resolving merge conflicts

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

Share

One test for each fix on the pull request below this one: a launch that
fails, a backslash off Windows, the shim's escaping and its answer for an
AppImage that has quit, a rebuild that did not end, a build that failed
after its folder appeared, and a page that is asking a question.

Claude-Session: https://claude.ai/code/session_018vwYjVhpwXLLdtgTUS3TnM

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant