Skip to content

Commit 8afaefd

Browse files
refactor: apply formatting
1 parent c4ec56d commit 8afaefd

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

src/mcp/client/session_group.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -154,7 +154,6 @@ async def __aexit__(
154154
for exit_stack in self._session_exit_stacks.values():
155155
tg.start_soon(exit_stack.aclose)
156156

157-
158157
@property
159158
def sessions(self) -> list[mcp.ClientSession]:
160159
"""Returns the list of sessions being managed."""

tests/client/test_session.py

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -451,7 +451,7 @@ async def mock_server():
451451
# Assert that capabilities are properly set with defaults
452452
assert received_capabilities is not None
453453
assert received_capabilities.sampling is None # No custom sampling callback
454-
assert received_capabilities.roots is None # No custom list_roots callback
454+
assert received_capabilities.roots is None # No custom list_roots callback
455455

456456

457457
@pytest.mark.anyio
@@ -536,8 +536,14 @@ async def mock_server():
536536

537537
# Assert that capabilities are properly set with custom callbacks
538538
assert received_capabilities is not None
539-
assert received_capabilities.sampling is not None # Custom sampling callback provided
539+
assert (
540+
received_capabilities.sampling is not None
541+
) # Custom sampling callback provided
540542
assert isinstance(received_capabilities.sampling, types.SamplingCapability)
541-
assert received_capabilities.roots is not None # Custom list_roots callback provided
543+
assert (
544+
received_capabilities.roots is not None
545+
) # Custom list_roots callback provided
542546
assert isinstance(received_capabilities.roots, types.RootsCapability)
543-
assert received_capabilities.roots.listChanged is True # Should be True for custom callback
547+
assert (
548+
received_capabilities.roots.listChanged is True
549+
) # Should be True for custom callback

0 commit comments

Comments
 (0)