(code: u16, message: &str)
| 2235 | } |
| 2236 | |
| 2237 | fn kube_api_error(code: u16, message: &str) -> KubeError { |
| 2238 | KubeError::Api(kube::core::ErrorResponse { |
| 2239 | status: if code == 404 { |
| 2240 | "404 Not Found".to_string() |
| 2241 | } else { |
| 2242 | "Failure".to_string() |
| 2243 | }, |
| 2244 | message: message.to_string(), |
| 2245 | reason: "Failed to parse error data".to_string(), |
| 2246 | code, |
| 2247 | }) |
| 2248 | } |
| 2249 | |
| 2250 | #[test] |
| 2251 | fn sandbox_api_version_probe_retries_on_structured_and_raw_404() { |
no outgoing calls