Skip to content

Speed up targeted opencode tests#27812

Open
kitlangton wants to merge 14 commits into
anomalyco:devfrom
kitlangton:autoresearch/test-suite-speed
Open

Speed up targeted opencode tests#27812
kitlangton wants to merge 14 commits into
anomalyco:devfrom
kitlangton:autoresearch/test-suite-speed

Conversation

@kitlangton
Copy link
Copy Markdown
Contributor

Summary

  • Add lightweight benchmark/profile scripts for packages/opencode test-suite research.
  • Reduce avoidable test setup in slow plugin, provider, workspace, SDK, config, and HTTP listener tests.
  • Record measured kept/discarded experiments in perf/test-suite.md.

Measurements

  • Final single full-suite benchmark: 225.069s via bun run bench:test.
  • Focused wins include httpapi-provider 7.905s -> 2.980s, TUI plugin lifecycle 7.330s -> 1.507s, SDK parity 8.011s -> 5.180s, workspace 12.949s -> 8.305s.

Verification

  • bunx prettier --check ...
  • file-scoped bunx oxlint ... (0 errors; existing warnings remain)
  • bun typecheck from packages/opencode
  • focused changed tests: bun run test -- test/plugin/install-concurrency.test.ts test/server/httpapi-listen.test.ts test/control-plane/workspace.test.ts test/config/config.test.ts test/server/httpapi-sdk.test.ts test/provider/provider.test.ts test/server/httpapi-provider.test.ts test/cli/tui/plugin-lifecycle.test.ts
  • bun run bench:test
  • pre-push bun turbo typecheck

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant