This commit is contained in:
Nikolay Kim 2023-10-02 14:30:19 +06:00
parent 37e3928d40
commit fd9ac5c48e
2 changed files with 8 additions and 9 deletions

View file

@ -126,6 +126,7 @@ mod tests {
use super::*;
use ntex_util::future::lazy;
#[allow(clippy::clone_on_copy)]
#[ntex::test]
async fn resolver() {
let resolver = Resolver::default().clone();

View file

@ -139,15 +139,13 @@ mod tests {
});
let mut cert_store = RootCertStore::empty();
cert_store.add_server_trust_anchors(webpki_roots::TLS_SERVER_ROOTS.0.iter().map(
|ta| {
OwnedTrustAnchor::from_subject_spki_name_constraints(
ta.subject,
ta.spki,
ta.name_constraints,
)
},
));
cert_store.add_trust_anchors(webpki_roots::TLS_SERVER_ROOTS.iter().map(|ta| {
OwnedTrustAnchor::from_subject_spki_name_constraints(
ta.subject,
ta.spki,
ta.name_constraints,
)
}));
let config = ClientConfig::builder()
.with_safe_defaults()
.with_root_certificates(cert_store)