Assert that encryption preference is still mutual

This commit is contained in:
link2xt
2022-11-04 18:57:18 +00:00
parent 053c9372cb
commit 96d2a7f0bf

View File

@@ -357,6 +357,7 @@ mod tests {
use super::*;
use crate::aheader::EncryptPreference;
use crate::e2ee;
use crate::mimeparser;
use crate::peerstate::Peerstate;
@@ -686,6 +687,9 @@ Authentication-Results: box.hispanilandia.net; spf=pass smtp.mailfrom=adbenitez@
.await?
.unwrap();
// Encryption preference is still mutual.
assert_eq!(bob_state.prefer_encrypt, EncryptPreference::Mutual);
// Also check that the keypair was not changed
assert_eq!(
bob_state.public_key.unwrap(),