Skip to content

Commit dd22d76

Browse files
committed
remove prints in the entire file
1 parent 32151a6 commit dd22d76

File tree

1 file changed

+3
-14
lines changed

1 file changed

+3
-14
lines changed

tests/server/fastmcp/auth/test_auth_integration.py

Lines changed: 3 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -221,7 +221,6 @@ def auth_app(mock_oauth_provider):
221221
def protected_resource_app(auth_app):
222222
"""Fixture to create protected resource routes for testing."""
223223

224-
print(auth_app.router.routes)
225224
# Create the protected resource routes
226225
protected_resource_routes = create_protected_resource_routes(
227226
resource_url=AnyHttpUrl("https://example.com/resource"),
@@ -355,11 +354,8 @@ class TestAuthEndpoints:
355354
@pytest.mark.anyio
356355
async def test_metadata_endpoint(self, test_client: httpx.AsyncClient):
357356
"""Test the OAuth 2.0 metadata endpoint."""
358-
print("Sending request to metadata endpoint")
357+
359358
response = await test_client.get("/.well-known/oauth-authorization-server")
360-
print(f"Got response: {response.status_code}")
361-
if response.status_code != 200:
362-
print(f"Response content: {response.content}")
363359
assert response.status_code == 200
364360

365361
metadata = response.json()
@@ -407,9 +403,7 @@ async def test_token_invalid_auth_code(self, test_client, registered_client, pkc
407403
"redirect_uri": "https://client.example.com/callback",
408404
},
409405
)
410-
print(f"Status code: {response.status_code}")
411-
print(f"Response body: {response.content}")
412-
print(f"Response JSON: {response.json()}")
406+
413407
assert response.status_code == 400
414408
error_response = response.json()
415409
assert error_response["error"] == "invalid_grant"
@@ -1229,15 +1223,10 @@ class TestProtectedResourceMetadata:
12291223
@pytest.mark.anyio
12301224
async def test_metadata_endpoint(self, protected_resource_app: Starlette, test_client: httpx.AsyncClient):
12311225
"""Test the OAuth 2.0 Protected Resource metadata endpoint."""
1232-
print("Sending request to protected resource metadata endpoint")
1226+
12331227
response = await test_client.get("/.well-known/oauth-protected-resource")
1234-
print(f"Got response: {response.status_code}")
1235-
if response.status_code != 200:
1236-
print(f"Response content: {response.content}")
12371228
assert response.status_code == 200
1238-
12391229
metadata = response.json()
1240-
print(f"Protected Resource Metadata: {metadata}")
12411230
assert metadata["resource"] == "https://example.com/resource"
12421231
assert metadata["authorization_servers"] == ["https://auth.example.com/authorization"]
12431232
assert metadata["scopes_supported"] == ["read", "write"]

0 commit comments

Comments
 (0)