From f7b5576bcc98995508f83cae5b46fe80cb00d93e Mon Sep 17 00:00:00 2001 From: "opencode-agent[bot]" Date: Mon, 18 May 2026 15:39:33 +0000 Subject: [PATCH] chore: generate --- .../server/httpapi-event-diagnostics.test.ts | 18 ++++-------------- .../opencode/test/server/httpapi-sdk.test.ts | 10 +++++----- 2 files changed, 9 insertions(+), 19 deletions(-) diff --git a/packages/opencode/test/server/httpapi-event-diagnostics.test.ts b/packages/opencode/test/server/httpapi-event-diagnostics.test.ts index 5967583993..eb1751a350 100644 --- a/packages/opencode/test/server/httpapi-event-diagnostics.test.ts +++ b/packages/opencode/test/server/httpapi-event-diagnostics.test.ts @@ -207,11 +207,7 @@ describe("/event SSE delivery diagnostics", () => { .pipe(Effect.provideService(InstanceRef, ctx)), ) - const collected = await collectUntil( - reader, - (event) => event.type === MessageV2.Event.PartUpdated.type, - 4_000, - ) + const collected = await collectUntil(reader, (event) => event.type === MessageV2.Event.PartUpdated.type, 4_000) const updated = collected.find((event) => event.type === MessageV2.Event.PartUpdated.type) expect(updated).toBeDefined() expect((updated as any).properties.part.id).toBe(partID) @@ -325,8 +321,7 @@ describe("/event SSE delivery diagnostics", () => { ]) const sseSaw = - Array.isArray(sseCollected) && - sseCollected.some((event) => event.type === MessageV2.Event.PartUpdated.type) + Array.isArray(sseCollected) && sseCollected.some((event) => event.type === MessageV2.Event.PartUpdated.type) const callbackSaw = callbackResult !== "timeout" // Both should see it. The reason we use a single assert with the boolean @@ -371,11 +366,7 @@ describe("/event SSE delivery diagnostics", () => { .pipe(Effect.provideService(InstanceRef, ctx)), ) - const collected = await collectUntil( - reader, - (event) => event.type === MessageV2.Event.PartUpdated.type, - 4_000, - ) + const collected = await collectUntil(reader, (event) => event.type === MessageV2.Event.PartUpdated.type, 4_000) const updated = collected.find((event) => event.type === MessageV2.Event.PartUpdated.type) expect(updated).toBeDefined() } finally { @@ -439,8 +430,7 @@ describe("/event SSE delivery diagnostics", () => { ]) const sseSaw = - Array.isArray(sseCollected) && - sseCollected.some((event) => event.type === MessageV2.Event.PartUpdated.type) + Array.isArray(sseCollected) && sseCollected.some((event) => event.type === MessageV2.Event.PartUpdated.type) const callbackSaw = callbackResult !== "timeout" expect({ sseSaw, callbackSaw }).toEqual({ sseSaw: true, callbackSaw: true }) } finally { diff --git a/packages/opencode/test/server/httpapi-sdk.test.ts b/packages/opencode/test/server/httpapi-sdk.test.ts index 9e6533a99c..a0a0d6d240 100644 --- a/packages/opencode/test/server/httpapi-sdk.test.ts +++ b/packages/opencode/test/server/httpapi-sdk.test.ts @@ -672,11 +672,11 @@ describe("HttpApi SDK", () => { ) // Regression: SyncEvent must publish on the same ProjectBus the /event handler -// subscribes to, AND the /event stream must forward handler ALS/context into the -// body-pump fiber. Drives the full SDK → /event → Session.updatePart → sync.run → -// bus.publish → SDK subscriber path. Goes red if either the publisher uses a -// different bus instance (Bug 2 / pre-#27825) or the stream loses context (Bug 1 / -// pre-#27425). + // subscribes to, AND the /event stream must forward handler ALS/context into the + // body-pump fiber. Drives the full SDK → /event → Session.updatePart → sync.run → + // bus.publish → SDK subscriber path. Goes red if either the publisher uses a + // different bus instance (Bug 2 / pre-#27825) or the stream loses context (Bug 1 / + // pre-#27425). serverPathParity("streams sync-backed part updates to /event subscribers", (serverPath) => withStandardProject(serverPath, ({ sdk, directory }) => Effect.gen(function* () {