test: add missing type hints to FakeProvider in test_utils (#631)

This commit is contained in:
marko1olo 2026-06-11 06:15:16 +04:00 committed by GitHub
parent 45b07bf754
commit 0d458e5d45
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -6,13 +6,13 @@ from headroom import utils
class FakeProvider:
def __init__(self, result):
def __init__(self, result: str | None) -> None:
self.result = result
self.calls: list[tuple[int, int, str, int]] = []
def estimate_cost(
self, input_tokens: int, output_tokens: int, model: str, cached_tokens: int = 0
):
) -> str | None:
self.calls.append((input_tokens, output_tokens, model, cached_tokens))
return self.result