Focused Bun parity tranche split from #66.
Current state:
js/bun/http/serve-body-leak.test.tsandbody-leak-test-fixture.tsare byte-identical to~/Code/bun- Home currently rewrites the complete seven-scenario stress corpus to one native TODO
- baseline: 0 active pass / 1 TODO
- the underlying native mimalloc allocator-retention issue was already fixed earlier; exact corpus coverage is still missing
Scope:
- activate all seven upstream 10,000-request memory-stability scenarios
- model long-lived spawned Bun.serve child lifecycle and IPC URL delivery
- account request-body acquisition/release for ignored, buffered, JSON, body-getter, streamed, and incompletely streamed paths
- transfer and release ownership correctly for streaming echo responses
- report stable post-GC RSS snapshots with peak/retained ownership evidence
- retain real parent-side batching, warmup, report sampling, and assertion logic
- keep both upstream fixtures untouched and add a durable exact-corpus regression
Acceptance:
- exact fixture passes seven active tests with zero failures/TODOs/unsupported cases
- adjacent request-body, streaming, response, spawn, and Bun.serve corpora remain green
- complete
home_testgate passes - implementation verifies balanced lifecycle transitions rather than returning a canned test result