fastapi-limiter
fastapi-limiter copied to clipboard
hashable & equalable
When writing unit tests, I'd like to use app.dependency_overrides to replace RateLimiter with a stub.
pseudo code
def test_hoge():
app: FastAPI
...
app.dependency_overrides[RateLimiter(times=60, minutes=1)] = lambda: True
related to:
- https://github.com/long2ice/fastapi-limiter/issues/27
@long2ice I would like you to confirm this change 🙏 And I hope you will release a newer version.