镜像站点 · 本页由第三方 GitHub 只读镜像提供,非 GitHub 官方站点,不接受任何登录或凭据输入。前往 github.com
Skip to content

test(server): cut the local server suite from ~63 to ~12-16 minutes - #58

Merged
Igloczek merged 1 commit into
mainfrom
test/faster-server-suite
Nov 5, 2026
Merged

Igloczek merged 1 commit into
mainfrom
test/faster-server-suite

Conversation

@Igloczek

@Igloczek Igloczek commented Nov 5, 2026

Copy link
Copy Markdown

The full local apps/server suite took about 63 minutes. It ran test files one at a time, and most of the time went to plugin integration tests waiting on real timers.

  • Fake terminal (PluginHost.testkit.ts). It never printed a shell prompt, so every setup script waited out ProjectSetupScriptRunner's 3s fallback and its 1s prompt wait. It now echoes input and prints a prompt the way a real terminal does. A plugin launch goes from 4.3s to 0.35s.
  • Login shell on every boot. Each test server ran the developer's login shell to read PATH (about 1s, and the result varied by machine). Test configs now set shellEnvironmentPrepared: true.
  • Telemetry. Test servers were sending real analytics to the ingest host and waiting on the final send at shutdown. A new telemetry.setup.ts turns telemetry off for server tests.
  • Parallel files. maxWorkers: "75%" replaces fileParallelism: false. Two Workflows *-direct tests turned off their simulated outage while a background drain could still hold a launch checked against the old provider or skill. They now run reconcile first, which waits on the drain lock, before turning the outage off.

Results on one 8-core machine:

Run Wall clock
Before (origin/main) 3795s
After, quiet machine 723s
After, under unrelated load 912s / 949s

All runs had only the 12 known failures. CI runs only the smoke files, so CI time doesn't change. An independent review agent read the diff and the code around it and ran the affected integration tests. It approved; its one nit, where a comment sat, is fixed.

🤖 Generated with Claude Code (Claude Opus 5.5)

The full apps/server suite ran files one at a time, and most of its plugin
integration time was real-time waiting rather than work:

- The pipe-backed PTY stand-in never showed a line-editor prompt, so every
  setup script waited out ProjectSetupScriptRunner's 3s quiet fallback and
  its 1s prompt-return timeout. It now echoes input and prints a prompt the
  way an interactive terminal does.
- Every test server boot spawned the user's login shell synchronously
  (~1s, host-dependent). Test configs now mark the shell environment as
  prepared.
- Test servers posted analytics to the real ingest host and waited on the
  shutdown flush. Server tests now disable telemetry.
- Files run in parallel at 75% of cores. Two workflow tests lifted their
  simulated outage while a scheduler-tick drain could still hold a launch
  validated against the old provider or skill; they now reconcile (drains
  are serialized) before lifting it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Igloczek
Igloczek merged commit ac47285 into main Nov 5, 2026
1 check passed
@Igloczek
Igloczek deleted the test/faster-server-suite branch November 5, 2026 19:38
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