We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 5c960e8 commit e166ba7Copy full SHA for e166ba7
tests/shared/test_streamable_http.py
@@ -1606,7 +1606,11 @@ async def bad_client():
1606
1607
@pytest.mark.anyio
1608
async def test_client_unexpected_content_type_raises_mcp_error():
1609
- """Test that unexpected content types raise McpError instead of just printing."""
+ """Test that unexpected content types raise McpError instead of just printing.
1610
+
1611
+ This test verifies that when a server returns HTML instead of MCP JSON,
1612
+ the client properly raises McpError wrapped in ExceptionGroup.
1613
+ """
1614
# Use a real server that returns HTML to test the actual behavior
1615
from starlette.responses import HTMLResponse
1616
from starlette.routing import Route
0 commit comments