Commit 24363b3e authored by iamwwc's avatar iamwwc
Browse files

test cfg. rename

parent 5c2cc874
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -3106,7 +3106,7 @@ impl SslRef {
    }
    #[corresponds(SSL_add1_chain_cert)]
    #[cfg(ossl102)]
    pub fn add_chain_cert_pem(&mut self, chain: X509) -> Result<(), ErrorStack> {
    pub fn add_chain_cert(&mut self, chain: X509) -> Result<(), ErrorStack> {
        let ret = unsafe { ffi::SSL_add1_chain_cert(self.as_ptr(), chain.as_ptr() as *mut _) };
        if ret == 1 {
            Ok(())
+3 −2
Original line number Diff line number Diff line
@@ -1415,9 +1415,10 @@ fn session_cache_size() {
}

#[test]
fn add_chain_cert_pem() {
#[cfg(ossl102)]
fn add_chain_cert() {
    let ctx = SslContext::builder(SslMethod::tls()).unwrap().build();
    let cert = X509::from_pem(CERT).unwrap();
    let mut ssl = Ssl::new(&ctx).unwrap();
    assert!(ssl.add_chain_cert_pem(cert).is_ok());
    assert!(ssl.add_chain_cert(cert).is_ok());
}