Pre-generate more keys for use in integration tests

This commit is contained in:
Floris Bruynooghe
2020-02-07 00:24:41 +01:00
committed by Alexander Krotov
parent 515c753d11
commit 1144a536a5
11 changed files with 32 additions and 6 deletions

View File

@@ -58,11 +58,7 @@ pub(crate) fn logging_cb(_ctx: &Context, evt: Event) {
///
/// This saves CPU cycles by avoiding having to generate a key.
///
/// The keypair was created using (this is purposefully not a doctest, it would be slow):
/// let keypair = crate::pgp::create_keypair(EmailAddress::new("alice@example.com"))
/// .unwrap();
/// println!("{}", keypair.public.to_base64(64));
/// println!("{}", keypair.secret.to_base64(64));
/// The keypair was created using the crate::key::tests::gen_key test.
pub(crate) fn alice_keypair() -> key::KeyPair {
let addr = EmailAddress::new("alice@example.com").unwrap();
let public =