forked from retoor/devplacepy
Gateway: refine routing, vision and request handling, update docs and tests
Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -153,7 +153,10 @@ def test_gateway_auth_and_routing(alice):
|
||||
headers={"Authorization": f"Bearer {admin_key}"},
|
||||
json={"messages": [{"role": "user", "content": "hi"}]},
|
||||
)
|
||||
assert with_admin.status_code == 502
|
||||
assert with_admin.status_code == 503, (
|
||||
"auth and consent passed, but the per-model breaker tripped on the "
|
||||
"unreachable upstream above now rejects the same model without a call"
|
||||
)
|
||||
finally:
|
||||
_config(page, gateway_access_key="")
|
||||
page.request.post(f"{BASE_URL}/admin/services/openai/start")
|
||||
|
||||
@@ -67,7 +67,10 @@ def test_embeddings_auth_passes_upstream_unreachable(alice):
|
||||
headers={"Authorization": f"Bearer {admin_key}"},
|
||||
json={"model": "molodetz~embed", "input": "hello"},
|
||||
)
|
||||
assert with_admin.status_code == 502
|
||||
assert with_admin.status_code == 503, (
|
||||
"auth and consent passed, but the per-model breaker tripped on the "
|
||||
"unreachable upstream above now rejects the same model without a call"
|
||||
)
|
||||
finally:
|
||||
_config(page, gateway_access_key="", gateway_embed_key="")
|
||||
page.request.post(f"{BASE_URL}/admin/services/openai/start")
|
||||
|
||||
Reference in New Issue
Block a user