ReviewOS

also looking at this

stacks/rpx

test: stop leaking mocked module state across test files

#2274
Merged glennmichael123 wants to merge fix/2270-2271-test-state-leaks into main
8 files +77 -67
packages/rpx/test/site-supervisor.test.tsmodified+4-0
Changes to packages/rpx/test/site-supervisor.test.ts
@@ -274,6 +274,10 @@ describe('SiteSupervisor', () => {
274274 probePort: async () => false,
275275 pollIntervalMs: 5,
276276 })
277 // Registered before the first await that can reject: the only one of these
278 // eight supervisors the afterEach could not reach, so its 30s reaper and
279 // readiness loop outlived a failing run (#2271).
280 supervisors.push(sup)
277281 await sup.onRequest('myapp.localhost')
278282 await sup.stopAll()
279283 expect(proc.signals).toContain('SIGTERM')