diff --git a/tests/end.cert b/tests/certs/end.cert similarity index 100% rename from tests/end.cert rename to tests/certs/end.cert diff --git a/tests/end.chain b/tests/certs/end.chain similarity index 100% rename from tests/end.chain rename to tests/certs/end.chain diff --git a/tests/end.rsa b/tests/certs/end.rsa similarity index 100% rename from tests/end.rsa rename to tests/certs/end.rsa diff --git a/tests/early-data.rs b/tests/early-data.rs index 42faad32..6008cb1d 100644 --- a/tests/early-data.rs +++ b/tests/early-data.rs @@ -65,10 +65,10 @@ async fn test_0rtt_vectored() -> io::Result<()> { } async fn test_0rtt_impl(vectored: bool) -> io::Result<()> { - let cert_chain = rustls_pemfile::certs(&mut Cursor::new(include_bytes!("end.cert"))) + let cert_chain = rustls_pemfile::certs(&mut Cursor::new(include_bytes!("certs/end.cert"))) .collect::>>()?; let key_der = - rustls_pemfile::private_key(&mut Cursor::new(include_bytes!("end.rsa")))?.unwrap(); + rustls_pemfile::private_key(&mut Cursor::new(include_bytes!("certs/end.rsa")))?.unwrap(); let mut server = ServerConfig::builder() .with_no_client_auth() .with_single_cert(cert_chain, key_der) @@ -109,7 +109,7 @@ async fn test_0rtt_impl(vectored: bool) -> io::Result<()> { }); }); - let mut chain = BufReader::new(Cursor::new(include_str!("end.chain"))); + let mut chain = BufReader::new(Cursor::new(include_str!("certs/end.chain"))); let mut root_store = RootCertStore::empty(); for cert in rustls_pemfile::certs(&mut chain) { root_store.add(cert.unwrap()).unwrap(); diff --git a/tests/test.rs b/tests/test.rs index 8a0ee7c0..b1b97635 100644 --- a/tests/test.rs +++ b/tests/test.rs @@ -15,9 +15,9 @@ use tokio::sync::oneshot; use tokio::{runtime, time}; use tokio_rustls::{LazyConfigAcceptor, TlsAcceptor, TlsConnector}; -const CERT: &str = include_str!("end.cert"); -const CHAIN: &[u8] = include_bytes!("end.chain"); -const RSA: &str = include_str!("end.rsa"); +const CERT: &str = include_str!("certs/end.cert"); +const CHAIN: &[u8] = include_bytes!("certs/end.chain"); +const RSA: &str = include_str!("certs/end.rsa"); lazy_static! { static ref TEST_SERVER: (SocketAddr, &'static str, &'static [u8]) = { diff --git a/tests/utils.rs b/tests/utils.rs index 94f7f12c..9e489bd9 100644 --- a/tests/utils.rs +++ b/tests/utils.rs @@ -8,9 +8,9 @@ mod utils { #[allow(dead_code)] pub fn make_configs() -> (Arc, Arc) { - const CERT: &str = include_str!("end.cert"); - const CHAIN: &str = include_str!("end.chain"); - const RSA: &str = include_str!("end.rsa"); + const CERT: &str = include_str!("certs/end.cert"); + const CHAIN: &str = include_str!("certs/end.chain"); + const RSA: &str = include_str!("certs/end.rsa"); let cert = certs(&mut BufReader::new(Cursor::new(CERT))) .map(|result| result.unwrap())