mirror of
https://github.com/meta-llama/llama-stack.git
synced 2025-12-23 08:52:28 +00:00
Fix auth test assertions to match updated error messages
Update test assertions in test_auth.py and test_auth_github.py to expect "Invalid Authorization header format" instead of "Missing or invalid Authorization header" to align with the error message changes made in the auth implementation. 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
parent
d07351bfcd
commit
409996695b
3 changed files with 5 additions and 5 deletions
|
|
@ -72,7 +72,7 @@ def test_authenticated_endpoint_with_invalid_bearer_format(github_token_client):
|
|||
"""Test accessing protected endpoint with invalid bearer format"""
|
||||
response = github_token_client.get("/test", headers={"Authorization": "InvalidFormat token123"})
|
||||
assert response.status_code == 401
|
||||
assert "Missing or invalid Authorization header" in response.json()["error"]["message"]
|
||||
assert "Invalid Authorization header format" in response.json()["error"]["message"]
|
||||
|
||||
|
||||
@patch("llama_stack.distribution.server.auth_providers.httpx.AsyncClient")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue