merge: preserve existing business features on new foundation

This commit is contained in:
张胜宇
2026-09-10 17:26:52 +08:00
56 changed files with 6923 additions and 20 deletions
@@ -73,6 +73,20 @@ async def test_unknown_path_is_not_found() -> None:
assert response.status_code == 404
def test_app_registers_platform_and_offsite_routes() -> None:
"""整合后的应用必须同时保留新底座平台路由和场外基金业务路由。"""
paths = {
child.path
for route in create_app().routes
if hasattr(route, "original_router")
for child in route.original_router.routes
if hasattr(child, "path")
}
assert "/api/v1/agent-runs" in paths
assert any(path.startswith("/api/v1/offsite-fund") for path in paths)
async def test_unauthorized_envelope_shape() -> None:
"""401 的错误信封必须与文档一致,否则客户端无法统一处理。"""
response = await send("GET", "/api/v1/agent-runs/run-x")