You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
24 lines
981 B
Python
24 lines
981 B
Python
# backend/tests/test_agents_research.py
|
|
def test_start_seed_query_ready(client):
|
|
r = client.post(
|
|
"/api/research/start",
|
|
json={"query": "최신 AI 반도체 시장 동향 — 보고서·논문·뉴스 종합해줘"},
|
|
).json()
|
|
assert r["status"] == "ready" and r["report_id"] == "rp1"
|
|
assert r["report"]["counts"][0]["n"] == 3
|
|
|
|
|
|
def test_start_freeform_queued(client):
|
|
r = client.post(
|
|
"/api/research/start", json={"query": "전고체 배터리 상용화 시점 정리해줘"}
|
|
).json()
|
|
assert r["status"] == "queued"
|
|
assert "전고체 배터리 상용화 시점 정리해줘" in r["queued_text"]
|
|
assert "끝나면 알림으로 알려드릴게요" in r["queued_text"]
|
|
|
|
|
|
def test_start_seed_prefix_ready(client):
|
|
# "최신 AI 반도체" prefix 도 골든
|
|
r = client.post("/api/research/start", json={"query": "최신 AI 반도체 시장 동향"}).json()
|
|
assert r["status"] == "ready" and r["report_id"] == "rp1"
|