mod test {
use super::*;
- use crate::validation::{parse_rr_stream, verify_rr_stream};
+ use crate::ser::parse_rr_stream;
+ use crate::validation::verify_rr_stream;
use minreq;
#[tokio::test(flavor = "multi_thread", worker_threads = 1)]
async fn test_lookup_a() {
- let ns = "4.4.4.4:53".parse().unwrap();
+ let ns = "9.9.9.9:53".parse().unwrap();
let listener = tokio::net::TcpListener::bind("127.0.0.1:17493").await
.expect("Failed to bind to socket");
tokio::spawn(imp::run_server(listener, ns));
assert_eq!(resp.status_code, 200);
let rrs = parse_rr_stream(resp.as_bytes()).unwrap();
let verified_rrs = verify_rr_stream(&rrs).unwrap();
- assert_eq!(verified_rrs.verified_rrs.len(), 1);
+ assert!(verified_rrs.verified_rrs.len() >= 1);
}
#[tokio::test(flavor = "multi_thread", worker_threads = 1)]
cargo test
cargo test --no-default-features --features std
cargo test --no-default-features --features tokio
+cargo test --no-default-features --features validation
+cargo test --features std,tokio,validation
cargo test --no-default-features --features build_server
cargo build --lib
cargo build --lib --features std
cargo build --lib --features tokio
+cargo build --lib --features validation
+cargo build --lib --features std,tokio,validation
cargo build --bin http_proof_gen --features build_server
cargo doc --features std,tokio,validation