rqlite_client 0.0.1-alpha.7

rqlite database client with optional extra convenience
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
//! `tls`

#[cfg(any(feature = "ureq_tls", feature = "ureq_webpki"))]
#[cfg(test)]
mod tests {
    use std::time::Duration;

    #[test]
    fn website_github_test() {
        let agt_builder = ureq::AgentBuilder::new()
            .https_only(true)
            .timeout(Duration::from_secs(5));
        let agent = agt_builder.build();
        let r = agent.get("https://github.com").call();
        assert!(r.is_ok(), "{:?}", r.unwrap_err());
        assert!((200..300).contains(&r.unwrap().status()));
    }
}