From ff8b1240971c6b437d01a9c451b8c5707259e71f Mon Sep 17 00:00:00 2001 From: Tony Arcieri Date: Wed, 7 Dec 2022 11:18:15 -0700 Subject: [PATCH] Fixups for upstream `ed25519` crate changes --- tests/ed25519.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/tests/ed25519.rs b/tests/ed25519.rs index 4bb7c244..5d0e135e 100644 --- a/tests/ed25519.rs +++ b/tests/ed25519.rs @@ -75,7 +75,7 @@ mod vectors { // The signatures in the test vectors also include the message // at the end, but we just want R and S. - let sig1: Signature = Signature::from_bytes(&sig_bytes[..64]).unwrap(); + let sig1: Signature = Signature::try_from(&sig_bytes[..64]).unwrap(); let sig2: Signature = keypair.sign(&msg_bytes); assert!(sig1 == sig2, "Signature bytes not equal on line {}", lineno); @@ -102,7 +102,7 @@ mod vectors { PublicKey::from_bytes(&pub_bytes[..PUBLIC_KEY_LENGTH]).unwrap(); let keypair: Keypair = Keypair::from(secret); assert_eq!(expected_public, keypair.public_key()); - let sig1: Signature = Signature::from_bytes(&sig_bytes[..]).unwrap(); + let sig1: Signature = Signature::try_from(&sig_bytes[..]).unwrap(); let mut prehash_for_signing: Sha512 = Sha512::default(); let mut prehash_for_verifying: Sha512 = Sha512::default();