pub trait UsageTransport {
// Required method
fn get(
&self,
url: &str,
token: &str,
timeout: Duration,
) -> Result<HttpResponse>;
}Expand description
Injected HTTP surface. UreqTransport is the default; tests use
a fake to exercise status-handling paths without real I/O. Errors
carry io::ErrorKind::TimedOut for timeouts; anything else is
treated as a generic network failure in fetch_usage.