mirror of
https://github.com/saymrwulf/curve25519-dalek-source.git
synced 2026-09-04 20:24:10 +00:00
Add a test for radix-51 multiplication
This commit is contained in:
parent
92bf47f990
commit
3a55a2f410
1 changed files with 8 additions and 0 deletions
|
|
@ -1034,6 +1034,14 @@ mod test {
|
|||
assert_eq!(asq, &a*&a);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn mul64_on_a() {
|
||||
let a: [u64;5] = [838547684720132, 293808819440897, 1085520638549020, 231251532116217, 416286470530165];
|
||||
let asq_constant_from_sage: [u64; 5] = [1696437425706869, 260630435370367, 277335390860868, 1743763050813710, 1739636627710249];
|
||||
let asq = mul64(&a, &a.clone());
|
||||
assert_eq!(asq, asq_constant_from_sage);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn a_square_vs_a_squared_constant() {
|
||||
let a = FieldElement::from_bytes(&A_BYTES);
|
||||
|
|
|
|||
Loading…
Reference in a new issue