mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-24 06:24:18 +02:00
Unify component storage in LocalProvider (#2680)
This commit is contained in:
parent
9147518c01
commit
f36b147f60
37 changed files with 4467 additions and 6015 deletions
|
|
@ -137,7 +137,7 @@ async def test_async_resource_with_task_true_remains_enabled():
|
|||
return "data"
|
||||
|
||||
# Resource should have task mode="optional" and be a FunctionResource
|
||||
resource = await mcp._resource_manager.get_resource("test://async")
|
||||
resource = await mcp.get_resource("test://async")
|
||||
assert isinstance(resource, FunctionResource)
|
||||
assert resource.task_config.mode == "optional"
|
||||
|
||||
|
|
@ -179,7 +179,7 @@ async def test_sync_resource_with_task_false_works():
|
|||
"""A synchronous resource."""
|
||||
return "data"
|
||||
|
||||
resource = await mcp._resource_manager.get_resource("test://sync")
|
||||
resource = await mcp.get_resource("test://sync")
|
||||
assert isinstance(resource, FunctionResource)
|
||||
assert resource.task_config.mode == "forbidden"
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue