mirror of
https://github.com/tinyhumansai/openhuman.git
synced 2026-07-27 21:08:00 +00:00
test(observability): cover custom_openai Ollama timeout chain (#3660)
This commit is contained in:
@@ -3152,6 +3152,20 @@ mod tests {
|
||||
}
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn custom_openai_ollama_timeout_fallback_chain_is_network_unreachable() {
|
||||
let chain =
|
||||
"custom_openai chat completions transport error: error sending request for url \
|
||||
(http://localhost:11434/v1/chat/completions): operation timed out \
|
||||
(responses fallback failed: custom_openai API error (404 Not Found): \
|
||||
{\"error\":\"not found\"})";
|
||||
assert_eq!(
|
||||
expected_error_kind(chain),
|
||||
Some(ExpectedErrorKind::NetworkUnreachable),
|
||||
"local Ollama timeout plus responses fallback failure must not page Sentry"
|
||||
);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn does_not_classify_unrelated_provider_errors_as_network() {
|
||||
// Status-bearing provider failures (404, 500, …) are surfaced via
|
||||
|
||||
Reference in New Issue
Block a user