fix: address coderabbit followups
This commit is contained in:
@@ -35,7 +35,8 @@ def _registry_entry(source_id: str) -> McpSourceRegistryEntry:
|
||||
|
||||
def test_wf_server_package_stays_mcp_free() -> None:
|
||||
path = "src/wf_server/context.py"
|
||||
tree = ast.parse(open(path, encoding="utf-8").read(), filename=path)
|
||||
with open(path, encoding="utf-8") as file:
|
||||
tree = ast.parse(file.read(), filename=path)
|
||||
|
||||
violations: list[str] = []
|
||||
for node in ast.walk(tree):
|
||||
|
||||
@@ -1,10 +1,14 @@
|
||||
from __future__ import annotations
|
||||
|
||||
from pathlib import Path
|
||||
|
||||
from wf_config import WorkflowConfigFile
|
||||
from wf_mcp.broker.config import broker_config_from_workflow_config
|
||||
|
||||
|
||||
def test_broker_config_from_workflow_config_converts_mcp_sources(tmp_path) -> None:
|
||||
def test_broker_config_from_workflow_config_converts_mcp_sources(
|
||||
tmp_path: Path,
|
||||
) -> None:
|
||||
workflow_config = WorkflowConfigFile.model_validate(
|
||||
{
|
||||
"version": 1,
|
||||
@@ -52,7 +56,9 @@ def test_broker_config_from_workflow_config_converts_mcp_sources(tmp_path) -> No
|
||||
assert connection.metadata["description"] == "Everything test server"
|
||||
|
||||
|
||||
def test_broker_config_from_workflow_config_converts_mcp_http_source(tmp_path) -> None:
|
||||
def test_broker_config_from_workflow_config_converts_mcp_http_source(
|
||||
tmp_path: Path,
|
||||
) -> None:
|
||||
workflow_config = WorkflowConfigFile.model_validate(
|
||||
{
|
||||
"version": 1,
|
||||
@@ -83,7 +89,9 @@ def test_broker_config_from_workflow_config_converts_mcp_http_source(tmp_path) -
|
||||
assert connection.metadata["headers"] == {"X-Test": "yes"}
|
||||
|
||||
|
||||
def test_broker_config_from_workflow_config_ignores_non_mcp_sources(tmp_path) -> None:
|
||||
def test_broker_config_from_workflow_config_ignores_non_mcp_sources(
|
||||
tmp_path: Path,
|
||||
) -> None:
|
||||
workflow_config = WorkflowConfigFile.model_validate(
|
||||
{
|
||||
"version": 1,
|
||||
|
||||
Reference in New Issue
Block a user