Load the test schema once and truncate data between files.
Deploy Development / deploy (push) Successful in 56s
Test Suite / pytest-backend (push) Successful in 2m43s
Test Suite / smoke-dev (push) Successful in 0s
Test Suite / frontend-build (push) Successful in 15s

Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
LarsandCursor committed 2026-09-07 15:07:33 +02:00
1 parent 3c0213ae74
commit 79e4fd0d4b
8 files changed
+78 -25

No files matched your search

+10 -5
View File
@@ -555,16 +555,21 @@ def _seed_runtime(conn: Any) -> None:
seed_generation_instructions(conn)
def refresh_runtime_seed() -> None:
"""Re-seed catalog rows after a data truncate. Schema must already exist."""
with get_db() as conn:
_seed_runtime(conn)
from writing_profile_store import bootstrap_from_existing
bootstrap_from_existing()
def init_db() -> None:
if use_postgres():
from db_init import ensure_postgres_ready
ensure_postgres_ready()
with get_db() as conn:
_seed_runtime(conn)
from writing_profile_store import bootstrap_from_existing
bootstrap_from_existing()
refresh_runtime_seed()
return
schema = SCHEMA_PATH.read_text(encoding="utf-8")