ai-code-review-agent / tests /conftest.py
Padmanav's picture
fix
bc23855
Raw
History Blame Contribute Delete
480 Bytes
import os
# Run Celery tasks synchronously and use an in-memory result backend for
# tests — must be set before app.worker.celery_app is imported anywhere.
os.environ.setdefault("CELERY_TASK_ALWAYS_EAGER", "true")
os.environ.setdefault("CELERY_RESULT_BACKEND", "cache+memory://")
import pytest
from app.api.routes import _clear_feedback_store
@pytest.fixture(autouse=True)
def clear_feedback_store() -> None:
_clear_feedback_store()
yield
_clear_feedback_store()