[techdebt] cleanup duplicate schema definitions

This commit is contained in:
Devin Zuczek
2026-08-11 15:50:55 -04:00
parent 1afa9b7ac3
commit ca8d40c4ec
16 changed files with 1873 additions and 2034 deletions
+2 -2
View File
@@ -4,7 +4,7 @@ import { beforeAll, describe, expect, test } from 'vitest'
import '../../clubs.app'
import { SCHEMA_DDL } from '../../clubs-db'
import { CLUB_SCHEMA_DDL } from '@repo/domain'
import type { Env } from '../../context'
@@ -18,7 +18,7 @@ beforeAll(async () => {
// Seed the shared JWT signing key into the local Secrets Store so .get() resolves.
await adminSecretsStore(env.JWT_SECRET).create('test-signing-key')
// Build the club / club_member tables (mirrors the migration).
for (const stmt of SCHEMA_DDL) await env.DB.prepare(stmt).run()
for (const stmt of CLUB_SCHEMA_DDL) await env.DB.prepare(stmt).run()
// Accounts table (owned by the auth worker) — a player's home club is a field on
// their account row, so /club/home/me reads and writes it here.