mirror of
https://github.com/BerriAI/litellm.git
synced 2026-09-21 00:21:49 +00:00
test(xai): narrow raises match for missing api key
Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
parent
4565bbee2f
commit
80b0ea6a2f
1 changed files with 1 additions and 1 deletions
|
|
@ -92,7 +92,7 @@ def test_validate_environment_sets_bearer_header():
|
|||
def test_validate_environment_requires_key(monkeypatch):
|
||||
monkeypatch.delenv("XAI_API_KEY", raising=False)
|
||||
monkeypatch.setattr(litellm, "xai_key", None)
|
||||
with pytest.raises(ValueError):
|
||||
with pytest.raises(ValueError, match="xAI API key is required"):
|
||||
CONFIG.validate_environment(
|
||||
headers={},
|
||||
model="grok-voice-transcribe-2.0",
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue