Files
wehub-resource-sync 60e0ffc959
Upgrade checks / Notify on failure (push) Has been cancelled
Upgrade checks / Close issue on success (push) Has been cancelled
Schema Crash Test / Real-world schema crash test (232K schemas) (push) Has been cancelled
Run static analysis / static_analysis (push) Has been cancelled
Tests / Tests: Python 3.10 on ubuntu-latest (push) Has been cancelled
Tests / Tests: Python 3.13 on ubuntu-latest (push) Has been cancelled
Tests / Tests: Python 3.10 on windows-latest (push) Has been cancelled
Tests / Tests with lowest-direct dependencies (push) Has been cancelled
Tests / MCP conformance tests (push) Has been cancelled
Tests / Integration tests (push) Has been cancelled
Tests / Package install smoke (push) Has been cancelled
Upgrade checks / Static analysis (push) Has been cancelled
Upgrade checks / Tests: Python 3.10 on ubuntu-latest (push) Has been cancelled
Upgrade checks / Tests: Python 3.13 on ubuntu-latest (push) Has been cancelled
Upgrade checks / Tests: Python 3.10 on windows-latest (push) Has been cancelled
Upgrade checks / Integration tests (push) Has been cancelled
Update MCPServerConfig Schema / update-config-schema (push) Has been cancelled
Update SDK Documentation / update-sdk-docs (push) Has been cancelled
chore: import upstream snapshot with attribution
2026-07-13 12:39:59 +08:00

24 lines
732 B
Python

import pytest
from starlette.applications import Starlette
from fastmcp import FastMCP
class TestRemovedKwargs:
def test_host_kwarg_raises_type_error(self):
with pytest.raises(TypeError, match="no longer accepts `host`"):
FastMCP(host="1.2.3.4")
def test_settings_property_removed(self):
mcp = FastMCP()
assert not hasattr(mcp, "_deprecated_settings")
with pytest.raises(AttributeError):
mcp.settings # noqa: B018 # ty: ignore[unresolved-attribute]
def test_http_app_with_sse_transport():
"""Test that http_app with SSE transport works."""
server = FastMCP("TestServer")
app = server.http_app(transport="sse")
assert isinstance(app, Starlette)