Skip to content

perf(tests): reduce native Git fixture setup cost - #607

Merged
norvalbv merged 1 commit into
mainfrom
codex/vitest-fixture-setup
Sep 6, 2026
Merged

perf(tests): reduce native Git fixture setup cost#607
norvalbv merged 1 commit into
mainfrom
codex/vitest-fixture-setup

Conversation

@norvalbv

@norvalbv norvalbv commented Sep 6, 2026

Copy link
Copy Markdown
Owner

Ship integration fixtures started an extra Node process supervisor for every setup Git command. Use direct native execution with a 90-second timeout before test hooks are installed. Actual test commands, hook-dispatching commits and their process-tree cleanup stay supervised. The timeout targets Git directly; no intermediate shell is introduced.

Five alternating fixture-phase pairs measured median child CPU 753.844ms → 143.530ms (81.0% less) and elapsed time 738.727ms → 231.705ms (68.6% less), with identical resulting repository state. These are initialization-phase measurements, not a whole-suite speedup claim. The reproducible runner, raw rows, append-only ledger and immutable checkpoints are included; the earlier shell-batch measurement is explicitly superseded.

Validation: all 118 focused integration tests passed across ship-fixture, ship-branch, ship-dry-gates and ship-base-and-self-checkout (631.85s). Typecheck, Fallow and the staged benchmark integrity check passed. Publication uses standard devkit ship gates; the full suite runs in PR CI. No gate bypass flags are used.

Ship integration fixtures started an extra Node process supervisor for every setup Git command. Use direct native execution with a 90-second timeout before test hooks are installed. Actual test commands, hook-dispatching commits and their process-tree cleanup stay supervised. The timeout targets Git directly; no intermediate shell is introduced.

Five alternating fixture-phase pairs measured median child CPU **753.844ms → 143.530ms (81.0% less)** and elapsed time **738.727ms → 231.705ms (68.6% less)**, with identical resulting repository state. These are initialization-phase measurements, not a whole-suite speedup claim. The reproducible runner, raw rows, append-only ledger and immutable checkpoints are included; the earlier shell-batch measurement is explicitly superseded.

Validation: all 118 focused integration tests passed across ship-fixture, ship-branch, ship-dry-gates and ship-base-and-self-checkout (631.85s). Typecheck, Fallow and the staged benchmark integrity check passed. Publication uses standard devkit ship gates; the full suite runs in PR CI. No gate bypass flags are used.
@coderabbitai

coderabbitai Bot commented Sep 6, 2026

Copy link
Copy Markdown
Contributor

Warning

Review limit reached

Next included review available in 35 minutes.

Check out review usage here.

View limit details

Limit details: You’ve used the included review currently available.

You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository.

Learn how review limits work.

Review configuration:

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Team

Run ID: 4c778834-658a-4956-9e23-80f3a1681b51

📥 Commits

Reviewing files that changed from the base of the PR and between 9b08577 and a34efe7.

⛔ Files ignored due to path filters (2)
  • docs/benchmarks/assets/dashboard-dark.svg is excluded by !**/*.svg
  • docs/benchmarks/assets/dashboard-light.svg is excluded by !**/*.svg
📒 Files selected for processing (14)
  • README.md
  • cli/__tests__/_ship-branch-fixture.mts
  • cli/__tests__/ship-fixture.test.mts
  • docs/benchmarks/README.md
  • docs/benchmarks/catalog.json
  • docs/benchmarks/checkpoints/1eb4fc03e88c86547f8505105c66fe1297400baecf16ef717c8ec090bb68f4c1.json
  • docs/benchmarks/checkpoints/407a8501dfd25d257737d317e96619e05a9c98acd9bea6457806db497332010d.json
  • docs/benchmarks/checkpoints/6799be49261b5a5774dd74e69d4aa6f85d448660e308e5d123da2d3620c794c8.json
  • docs/benchmarks/history.jsonl
  • docs/benchmarks/vitest-fixture-benchmark.py
  • docs/benchmarks/vitest-fixture-results.json
  • docs/benchmarks/vitest-fixture-setup.md
  • docs/decisions/suite-hangs-bound-at-the-spawn-site.md
  • vitest.config.mjs

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

Comment @coderabbitai help to get the list of available commands.

@norvalbv
norvalbv merged commit ff811df into main Sep 6, 2026
1 of 2 checks passed
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