Skip to content

πŸš€ The fast, Pythonic way to build MCP servers and clients.

Fix flaky timing test on Windows CI

Georgios Rorosee6f469aa51e
diff --git a/tests/server/providers/openapi/test_comprehensive.py b/tests/server/providers/openapi/test_comprehensive.py
index a21a764db..5396767c2 100644
--- a/tests/server/providers/openapi/test_comprehensive.py
+++ b/tests/server/providers/openapi/test_comprehensive.py
@@ -731,9 +731,11 @@ class TestOpenAPIComprehensive:
end_time = time.time()
- # Should be very fast (no code generation)
+ # Should be fast (no code generation). Use generous threshold for slow
+ # CI runners (Windows); the intent is to catch obvious regressions
+ # (e.g., accidentally re-introducing code generation), not to benchmark.
initialization_time = end_time - start_time
- assert initialization_time < 0.1 # Should be under 100ms
+ assert initialization_time < 1.0
# Verify provider was created correctly
assert provider is not None