diff --git a/doc/RELEASE-AUTOMATION-SETUP.md b/doc/RELEASE-AUTOMATION-SETUP.md index 510c464e3f..3eaf5ceac2 100644 --- a/doc/RELEASE-AUTOMATION-SETUP.md +++ b/doc/RELEASE-AUTOMATION-SETUP.md @@ -365,8 +365,9 @@ See [GitHub cache access restrictions](https://docs.github.com/en/actions/refere Release verification runs the large chat integration file on three independent runners. Four other server shards cover every remaining general server file. The ordinary local test command and trusted PR workflow keep their complete -`general-server` group. Each chat case shuts down its services and pauses its own still-active endpoints -after assertions. This keeps workers in later cases from claiming earlier +`general-server` group. Each chat case shuts down its services, pauses its own +still-active endpoints, and retires its active/waiting conversations after +assertions. This keeps workers in later cases from claiming earlier fixtures in the shared test database. Application assertions stay unchanged. Each chat job collects active tests with Vitest, groups cases by source line, diff --git a/server/src/__tests__/chat-channels.integration.test.ts b/server/src/__tests__/chat-channels.integration.test.ts index 4de026c40e..61ecfec616 100644 --- a/server/src/__tests__/chat-channels.integration.test.ts +++ b/server/src/__tests__/chat-channels.integration.test.ts @@ -1033,6 +1033,10 @@ describeEmbeddedPostgres("chat channel control-plane integration", () => { if (fixtureCompanies.size > 0) { await db.update(chatEndpoints).set({ status: "paused" }) .where(and(inArray(chatEndpoints.companyId, [...fixtureCompanies]), eq(chatEndpoints.status, "active"))); + // The milestone scanner also considers paused endpoints while their + // conversations are active. Retire those bindings after assertions. + await db.update(chatConversations).set({ state: "completed" }) + .where(and(inArray(chatConversations.companyId, [...fixtureCompanies]), inArray(chatConversations.state, ["active", "waiting"]))); } fixtureServices.clear(); fixtureCompanies.clear();