Remove firestore emulator from test dependencies

This commit is contained in:
2026-03-05 05:55:09 +00:00
parent bc23ca27e4
commit 5941c41296
2 changed files with 287 additions and 5 deletions

View File

@@ -2,25 +2,23 @@
from __future__ import annotations
import os
import uuid
import pytest
import pytest_asyncio
from google.cloud.firestore_v1.async_client import AsyncClient
from va_agent.session import FirestoreSessionService
os.environ.setdefault("FIRESTORE_EMULATOR_HOST", "localhost:8602")
from .fake_firestore import FakeAsyncClient
@pytest_asyncio.fixture
async def db():
return AsyncClient(project="test-project")
return FakeAsyncClient()
@pytest_asyncio.fixture
async def service(db: AsyncClient):
async def service(db):
prefix = f"test_{uuid.uuid4().hex[:8]}"
return FirestoreSessionService(db=db, collection_prefix=prefix)