feat: manual match pin/unpin endpoints

This commit is contained in:
2026-05-06 06:24:17 -07:00
parent db4b01337e
commit 3d5f0c2668
4 changed files with 147 additions and 2 deletions
+13
View File
@@ -155,6 +155,19 @@ def db(_engine):
connection.close()
@pytest.fixture()
def db_session():
"""Plain SessionLocal for tests that need to seed data outside the
transactional ``db`` fixture (e.g. setting up rows the API will read)."""
from app.database import SessionLocal
s = SessionLocal()
try:
yield s
finally:
s.close()
@pytest.fixture()
def client(db):
"""TestClient with get_db overridden to yield the test session."""