docs added,
This commit is contained in:
@@ -82,3 +82,47 @@ def test_unified_server_can_hide_admin_tools() -> None:
|
||||
assert "wf.admin.list_connections" not in names
|
||||
|
||||
asyncio.run(run_proxy())
|
||||
|
||||
|
||||
def test_unified_workflow_tools_have_human_metadata() -> None:
|
||||
config = BrokerConfig(
|
||||
store_root=local_temp_root() / "unified_metadata_store",
|
||||
connections=[],
|
||||
)
|
||||
|
||||
async def run_proxy() -> None:
|
||||
client = create_unified_proxy_client(config, admin_tools=False)
|
||||
async with client:
|
||||
tools = await client.list_tools()
|
||||
by_name = {tool.name: tool for tool in tools}
|
||||
list_artifacts = by_name["wf.workflow.list_artifacts"]
|
||||
run_deployment = by_name["wf.workflow.run_deployment"]
|
||||
|
||||
assert list_artifacts.title == "List Workflow Artifacts"
|
||||
assert "saved workflow artifacts" in (list_artifacts.description or "")
|
||||
assert run_deployment.title == "Run Workflow Deployment"
|
||||
assert "deployment_id" in (run_deployment.description or "")
|
||||
|
||||
asyncio.run(run_proxy())
|
||||
|
||||
|
||||
def test_unified_admin_tools_have_human_metadata() -> None:
|
||||
config = BrokerConfig(
|
||||
store_root=local_temp_root() / "unified_admin_metadata_store",
|
||||
connections=[],
|
||||
)
|
||||
|
||||
async def run_proxy() -> None:
|
||||
client = create_unified_proxy_client(config)
|
||||
async with client:
|
||||
tools = await client.list_tools()
|
||||
by_name = {tool.name: tool for tool in tools}
|
||||
list_connections = by_name["wf.admin.list_connections"]
|
||||
reload_config = by_name["wf.admin.reload_config"]
|
||||
|
||||
assert list_connections.title == "List Connections"
|
||||
assert "configured MCP connections" in (list_connections.description or "")
|
||||
assert reload_config.title == "Reload Config"
|
||||
assert "remount" in (reload_config.description or "")
|
||||
|
||||
asyncio.run(run_proxy())
|
||||
|
||||
Reference in New Issue
Block a user