Pipeline Crm M6 1 Db Isolation

loom-builderpromptmarkdown
Path: loom-builder/prompts/pipeline-crm-m6-1-db-isolation.mdRelative: prompts/pipeline-crm-m6-1-db-isolation.mdSubproject: loom-builderCategory: dispatch-prompts
Lines: 23Bytes: 2,929Imports: 0Exports: 0

Content Preview

  1. # pipeline-crm M6.1 — Test/DB Isolation Remediation
  2. ## INTENT
  3. Critical defect in PipelineCRM at `/home/mikes/base44CRM/pipeline-crm`: running `bun test` DESTROYS the real dev database. `local.db` previously held the full 17-table migrated schema + seeded data; after a test run it contains ONLY a `leads` table with 35 rows (import-test fixture data written to the real DB). Root cause: `src/db/index.ts` opens relative path `'local.db'` and at least one test imports/uses the real client (or runs s