mirror of
https://github.com/chatmail/core.git
synced 2026-04-02 05:22:14 +03:00
test: set some address for test context in decrypt_bytes()
This is needed to create pseudo transport, otherwise public key generation fails.
This commit is contained in:
@@ -589,6 +589,7 @@ mod tests {
|
||||
|
||||
use super::*;
|
||||
use crate::{
|
||||
config::Config,
|
||||
decrypt,
|
||||
key::{load_self_public_key, self_fingerprint, store_self_keypair},
|
||||
mimefactory::{render_outer_message, wrap_encrypted_part},
|
||||
@@ -604,6 +605,9 @@ mod tests {
|
||||
auth_tokens_for_decryption: &[String],
|
||||
) -> Result<pgp::composed::Message<'static>> {
|
||||
let t = &TestContext::new().await;
|
||||
t.set_config(Config::ConfiguredAddr, Some("alice@example.org"))
|
||||
.await
|
||||
.expect("Failed to configure address");
|
||||
|
||||
for secret in auth_tokens_for_decryption {
|
||||
token::save(t, token::Namespace::Auth, None, secret, 0).await?;
|
||||
|
||||
Reference in New Issue
Block a user