Skip to content

armgit / crm

Public Imported from GitHub
0

Comp AI CRM is an open source, CRM designed for AI agents. Agentic-first CRM.

TypeScript

feat(turbo): update test dependencies and document workspace behavior

Lewis Carhart6d2e6e445c06
diff --git a/apps/agent/turbo.json b/apps/agent/turbo.json
index 25049716..0f8bc0bd 100644
--- a/apps/agent/turbo.json
+++ b/apps/agent/turbo.json
@@ -22,8 +22,25 @@
"RAPIDAPI_KEY"
]
},
+ /**
+ * `@crm/auth#test` is not a build dependency — it is a lock.
+ *
+ * Every other fixture in these suites is namespaced with `TEST_RUN_ID`,
+ * but the workspace cannot be: it is a singleton by design, one row whose
+ * id is the literal string `workspace`. `packages/auth`'s organization
+ * spec deletes and recreates that row in `beforeEach`, and this app's
+ * preamble spec reads it twice inside one assertion — once to compose the
+ * expected "Who we are" block, once per preamble it checks against it.
+ * Run in parallel against one Postgres, a delete landing between those
+ * reads fails `ends each preamble with the same account of us`, and it
+ * fails on whichever pull request happened to be unlucky.
+ *
+ * Turborepo has no mutex, so the dependency edge is the mutex. Everything
+ * else still runs in parallel; only these two are ordered. The real fix is
+ * a schema per package so nothing shares a row in the first place.
+ */
"test": {
- "dependsOn": ["topo", "^build"],
+ "dependsOn": ["topo", "^build", "@crm/auth#test"],
"passThroughEnv": ["DATABASE_URL"]
}
}