MCPcopy
hub / github.com/HisMax/RedInk / test_classifies_fake_ip_tls_error

Function test_classifies_fake_ip_tls_error

tests/errors_test.py:8–24  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

6
7
8def test_classifies_fake_ip_tls_error():
9 error = classify_error(
10 "HTTPSConnectionPool(host='api.apiyi.com', port=443): "
11 "Max retries exceeded with url: /v1/models "
12 "(Caused by SSLError(SSLEOFError(8, '[SSL: UNEXPECTED_EOF_WHILE_READING] EOF occurred')))",
13 context={
14 "provider": "APIYI",
15 "base_url": "https://api.apiyi.com",
16 "endpoint": "/v1/models",
17 },
18 )
19
20 assert error.code == "NETWORK_FAKE_IP_TLS"
21 assert error.retryable is True
22 assert error.status == 400
23 assert error.diagnostics["provider"] == "APIYI"
24 assert error.diagnostics["endpoint"] == "/v1/models"
25
26
27def test_classifies_proxy_unavailable():

Callers

nothing calls this directly

Calls 1

classify_errorFunction · 0.90

Tested by

no test coverage detected