Skip to content

Commit

Permalink
MVPoly: add tests for double
Browse files Browse the repository at this point in the history
  • Loading branch information
dannywillems committed Aug 26, 2024
1 parent b71dec2 commit 40f2e4a
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions mvpoly/tests/prime.rs
Original file line number Diff line number Diff line change
Expand Up @@ -184,3 +184,12 @@ fn test_add_zero() {
let p3 = zero.clone() + p1.clone();
assert_eq!(p1.clone(), p3);
}

#[test]
fn test_double_is_add_twice() {
let mut rng = o1_utils::tests::make_test_rng(None);
let p1 = Dense::<Fp, 3, 4>::random(&mut rng);
let p2 = p1.clone() + p1.clone();
let p3 = p1.clone().double();
assert_eq!(p2, p3);
}

0 comments on commit 40f2e4a

Please sign in to comment.