Apply black fixes

This commit is contained in:
Hugh Brown
2026-03-04 06:54:10 -07:00
committed by Abhimanyu Saharan
parent fc9fc1661c
commit fe310b50dc

View File

@@ -272,9 +272,7 @@ def test_factory_returns_memory_by_default(monkeypatch: pytest.MonkeyPatch) -> N
def test_factory_returns_redis_when_configured(monkeypatch: pytest.MonkeyPatch) -> None: def test_factory_returns_redis_when_configured(monkeypatch: pytest.MonkeyPatch) -> None:
monkeypatch.setattr("app.core.config.settings.rate_limit_backend", RateLimitBackend.REDIS) monkeypatch.setattr("app.core.config.settings.rate_limit_backend", RateLimitBackend.REDIS)
monkeypatch.setattr( monkeypatch.setattr("app.core.config.settings.rate_limit_redis_url", "redis://localhost:6379/0")
"app.core.config.settings.rate_limit_redis_url", "redis://localhost:6379/0"
)
fake = _FakeRedis() fake = _FakeRedis()
with patch("redis.Redis.from_url", return_value=fake): with patch("redis.Redis.from_url", return_value=fake):
limiter = create_rate_limiter(namespace="test", max_requests=10, window_seconds=60.0) limiter = create_rate_limiter(namespace="test", max_requests=10, window_seconds=60.0)