recon + sqlglot validator + drill_down package; guard ReAct dimension picks against candidate list
This commit is contained in:
23
tests/test_analyses_registry.py
Normal file
23
tests/test_analyses_registry.py
Normal file
@@ -0,0 +1,23 @@
|
||||
"""Regression: Analysis registry exposes the expected Analyses."""
|
||||
|
||||
from api.analyses.registry import REGISTRY, catalog, get
|
||||
|
||||
|
||||
def test_registry_has_expected_analyses():
|
||||
assert set(REGISTRY) >= {"direct_answer", "compare_periods", "drill_down"}
|
||||
|
||||
|
||||
def test_registry_get_returns_instance_or_none():
|
||||
a = get("direct_answer")
|
||||
assert a is not None
|
||||
assert a.name == "direct_answer"
|
||||
assert get("does_not_exist") is None
|
||||
|
||||
|
||||
def test_catalog_shape_for_planner():
|
||||
cat = catalog()
|
||||
names = {entry["name"] for entry in cat}
|
||||
assert names >= {"direct_answer", "compare_periods", "drill_down"}
|
||||
for entry in cat:
|
||||
assert isinstance(entry["description"], str) and entry["description"]
|
||||
assert isinstance(entry["args_schema"], dict)
|
||||
Reference in New Issue
Block a user