OffGridSchedula / tests /conftest.py
ParetoOptimal's picture
Initial Commit
0366d65
Raw
History Blame Contribute Delete
739 Bytes
"""Pytest config: force stub mode + isolate side-effect paths, and make the repo
root importable so `server`, `calendar_out`, `ui` resolve."""
import os
import sys
import tempfile
from pathlib import Path
os.environ["USE_STUB_EXTRACTOR"] = "1"
os.environ.setdefault("FEED_PATH", os.path.join(tempfile.gettempdir(), "ci_feed.json"))
os.environ.setdefault("IMPACT_PATH", os.path.join(tempfile.gettempdir(), "ci_impact.json"))
os.environ.setdefault("DEDUP_PATH", os.path.join(tempfile.gettempdir(), "ci_dedup.json"))
os.environ.setdefault("MEMORY_PATH", os.path.join(tempfile.gettempdir(), "ci_memory.json"))
os.environ.setdefault("INGEST_TOKEN", "test-token")
sys.path.insert(0, str(Path(__file__).resolve().parent.parent))