Preserve chat fixture prefix uniqueness across test runs

Use the complete company UUID instead of a resettable counter. Planning evaluation sources and production guidance are unchanged.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
DottaandPaperclip committed 2026-10-05 21:14:54 -05:00
1 parent 8538cfce4c
commit 9f5c4e5bd6
2 files changed
+8 -5

No files matched your search

+7 -3
View File
@@ -89,6 +89,10 @@ Repository checks at the previous source: full typecheck and build pass. Local
full tests: 9,591 pass, 5,796 skip and one unchanged macOS real-Git streaming test
hits its five-minute deadline; an isolated check also fails. Preserve this
limitation. Normal CI found a different, exact cause: truncated random fixture
company prefixes collided in chat integration setup. A monotonic per-suite
prefix removes that collision; all five affected native-modal variants pass
locally (1,058 unrelated cases filtered). This is a test-only repair.
company prefixes collided in chat integration setup. An initial per-suite counter fixed within-run collisions but review found that
its values repeat against an external database on subsequent runs. The corrected
prefix contains the complete company UUID, with no truncation; distinct company
IDs therefore produce distinct prefixes within and across runs. All five affected
native-modal variants pass locally (1,058 unrelated cases filtered). This is a
test-only repair; the measured planning fixture and production guidance remain
frozen at `8538cfce4c2defdedc2efba7519bcfce880c4e00`.
@@ -1080,7 +1080,6 @@ describeEmbeddedPostgres("chat channel control-plane integration", () => {
.where(and(inArray(chatConversations.companyId, companyIds), inArray(chatConversations.state, ["active", "waiting"])));
}
let fixtureCompanySequence = 0;
async function seedCompany() {
const companyId = randomUUID();
fixtureCompanies.add(companyId);
@@ -1089,7 +1088,7 @@ describeEmbeddedPostgres("chat channel control-plane integration", () => {
await db.insert(companies).values({
id: companyId,
name: `Chat Test ${companyId.slice(0, 8)}`,
issuePrefix: `C${(++fixtureCompanySequence).toString(36).padStart(7, "0").toUpperCase()}`,
issuePrefix: `C${companyId.replace(/-/g, "").toUpperCase()}`,
requireBoardApprovalForNewAgents: false,
});
const now = new Date();