Skip to content

test(cli): use one terminal backend for CLI screenshots - #1747

Open
John-David Dalton (jdalton) wants to merge 1 commit into
v1.xfrom
test/trim-unused-snapshot-code
Open

John-David Dalton (jdalton) wants to merge 1 commit into
v1.xfrom
test/trim-unused-snapshot-code

Conversation

@jdalton

@jdalton John-David Dalton (jdalton) commented Nov 20, 2026 •

Copy link
Copy Markdown
Contributor

LLM Description written by Codex:GPT-6

The Termless end-to-end suite builds the npm CLI, launches its published entry point (bin/cli.js) in a real terminal, runs socket scan setup, and selects cancel. The two screenshots show the command menu and the cancellation output. They replace the old screenshots of a node -e demo.

The test uses the same xterm backend as the native CLI tests, so this removes the second backend dependency. The recorder accepts live terminal captures directly. The native binary tests still exercise scan setup, manifest setup and the TUI in their own CI step.

Run pnpm exec vitest run --config .config/vitest.terminal.config.mts to build the CLI and compare its output to the screenshots. CI runs the same command. Verified the terminal suite and snapshot refresh argument tests locally.

Follow-up to socket-mcp#241.

CI fixes

The npm CLI builds with the root package version. The native CLI builds with the SEA release policy, which currently selects a 2.1 release candidate. The native verifier now uses the same expected version as the builder. The release workflow test checks the npm tag for the active release line.

The macOS runner uses the existing 4 GB build heap setting for the terminal suite. The scan setup screenshot uses a wider terminal so the Windows temporary path fits before normalization. A screenshot failure prints the captured rows in the job log.

The scan reach tests that expect an invalid token use a loopback HTTP server returning 401. The analytics-disabled case checks the status and runs without a live Socket API call.

@cursor

cursor Bot commented Nov 20, 2026 •

Copy link
Copy Markdown

PR Summary

Low Risk
Test-only dependency removal and recorder API tightening with no production CLI behavior changes.

Overview
Removes the synthetic PTY Enter screenshot flow and its only consumer @termless/vterm, including lockfile entries and the deleted test/e2e/termless.test.mts. Terminal Vitest config and terminalSnapshotArgs now refresh only test/termless/utils/self-update.test.mts.

The termless animation helpers now treat captured as required on every checkpoint and createRecording assumes live captures (shared width, common trimmed height) instead of accepting bare SVG fixtures. Unit tests follow that model: optional captured? access is gone, the manual freeze/copy case is dropped, and the sequence-regression test builds recordings from two real xterm captures.

Reviewed by Cursor Bugbot for commit 4ab96f1. Configure here.

@jdalton John-David Dalton (jdalton) changed the title Remove unused terminal snapshot code Use one terminal backend for CLI screenshots Nov 20, 2026
@jdalton John-David Dalton (jdalton) changed the title Use one terminal backend for CLI screenshots test(cli): use one terminal backend for CLI screenshots Nov 21, 2026

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

Development

Successfully merging this pull request may close these issues.

1 participant