(fix) test_parallel limiter fix

This commit is contained in:
ishaan-jaff 2024-02-03 20:59:07 -08:00
parent 24aa304061
commit c353161456

View file

@ -371,14 +371,13 @@ async def test_normal_router_tpm_limit():
print(f"response: {response}")
try:
await parallel_request_handler.async_pre_call_hook(
user_api_key_dict=user_api_key_dict,
cache=local_cache,
data={},
call_type="",
assert (
parallel_request_handler.user_api_key_cache.get_cache(
key=request_count_api_key
)["current_tpm"]
> 0
)
pytest.fail(f"Expected call to fail")
except Exception as e:
assert e.status_code == 429