File size: 958 Bytes
fdfe81a
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
"""Pytest config for apps/api.

Loads apps/api/.env before tests start so RUN_LIVE=1 smoke tests pick up the
project-local OPENAI_API_KEY without requiring it to be exported in the shell.
Real shell env still wins (override=False).

Also pins ``SLIDE_REVIEWER_MODE=agentic`` for the test process. Production
defaults to ``single_shot`` (multimodal pre-computed bundle, one turn) but
the existing runner mocks marshal a JSON briefing into the agent's input
and inspect ``agent.name == "Slide Reviewer"`` — both still work in agentic
mode unchanged. Tests that exercise the single-shot path opt in explicitly
via monkeypatch.
"""
import os
from pathlib import Path

from dotenv import load_dotenv

load_dotenv(Path(__file__).parent / ".env", override=True)

# Pin tests to the legacy briefing-only flow unless a test explicitly
# overrides via monkeypatch.setenv("SLIDE_REVIEWER_MODE", "single_shot").
os.environ.setdefault("SLIDE_REVIEWER_MODE", "agentic")