mirror of
https://github.com/PrefectHQ/fastmcp.git
synced 2026-08-09 07:09:11 +02:00
13 lines
607 B
Python
13 lines
607 B
Python
import pytest
|
|
|
|
# reset deprecation warnings for this module
|
|
pytestmark = pytest.mark.filterwarnings("default::DeprecationWarning")
|
|
|
|
|
|
def test_bearer_auth_provider_deprecated():
|
|
"""Test that BearerAuthProvider import shows deprecation warning."""
|
|
with pytest.warns(
|
|
DeprecationWarning,
|
|
match="The `fastmcp.server.auth.providers.bearer` module is deprecated and will be removed in a future version. Please use `fastmcp.server.auth.providers.jwt.JWTVerifier` instead of this module's BearerAuthProvider.",
|
|
):
|
|
from fastmcp.server.auth import BearerAuthProvider # noqa: F401
|