fix: resolve lifecycle memory leaks by cleaning up listeners and root closures (#25049)

This commit is contained in:
Spencer
2026-04-10 00:21:14 -04:00
committed by GitHub
parent 43b93e9e1b
commit 5fc8fea8d7
8 changed files with 108 additions and 18 deletions
+2 -1
View File
@@ -1428,12 +1428,13 @@ describe('startInteractiveUI', () => {
vi.mock('./ui/utils/updateCheck.js', () => ({
checkForUpdates: vi.fn(() => Promise.resolve(null)),
}));
vi.mock('./utils/cleanup.js', () => ({
cleanupCheckpoints: vi.fn(() => Promise.resolve()),
registerCleanup: vi.fn(),
removeCleanup: vi.fn(),
runExitCleanup: vi.fn(),
registerSyncCleanup: vi.fn(),
removeSyncCleanup: vi.fn(),
registerTelemetryConfig: vi.fn(),
setupSignalHandlers: vi.fn(),
setupTtyCheck: vi.fn(() => vi.fn()),