diff --git a/src/pasta/pallas.rs b/src/pasta/pallas.rs index c3094ef..eb24f82 100644 --- a/src/pasta/pallas.rs +++ b/src/pasta/pallas.rs @@ -106,7 +106,7 @@ fn test_map_to_curve_simple_swu() { // The zero input is a special case. let p: IsoEp = map_to_curve_simple_swu::(&Fp::zero(), Ep::THETA, Ep::Z); let (x, y, z) = p.jacobian_coordinates(); - println!("{:?}", p); + assert!( format!("{:?}", x) == "0x28c1a6a534f56c52e25295b339129a8af5f42525dea727f485ca3433519b096e" ); @@ -119,7 +119,7 @@ fn test_map_to_curve_simple_swu() { let p: IsoEp = map_to_curve_simple_swu::(&Fp::one(), Ep::THETA, Ep::Z); let (x, y, z) = p.jacobian_coordinates(); - println!("{:?}", p); + assert!( format!("{:?}", x) == "0x010cba5957e876534af5e967c026a1856d64b071068280837913b9a5a3561505" ); @@ -141,7 +141,7 @@ fn test_hash_to_curve() { let hash = Point::hash_to_curve("z.cash:test"); let p: Point = hash(b"world"); let (x, y, z) = p.jacobian_coordinates(); - println!("{:?}", p); + assert!( format!("{:?}", x) == "0x2ae2d9bde5a5b4bc1f1e7154f18a407ac826c9d7cd23c3b33efa0f237e99cd35" ); diff --git a/src/pasta/vesta.rs b/src/pasta/vesta.rs index c958804..8dc6d2e 100644 --- a/src/pasta/vesta.rs +++ b/src/pasta/vesta.rs @@ -23,7 +23,7 @@ fn test_map_to_curve_simple_swu() { // The zero input is a special case. let p: IsoEq = map_to_curve_simple_swu::(&Fq::zero(), Eq::THETA, Eq::Z); let (x, y, z) = p.jacobian_coordinates(); - println!("{:?}", p); + assert!( format!("{:?}", x) == "0x2ccc4c6ec2660e5644305bc52527d904d408f92407f599df8f158d50646a2e78" ); @@ -36,7 +36,7 @@ fn test_map_to_curve_simple_swu() { let p: IsoEq = map_to_curve_simple_swu::(&Fq::one(), Eq::THETA, Eq::Z); let (x, y, z) = p.jacobian_coordinates(); - println!("{:?}", p); + assert!( format!("{:?}", x) == "0x165f8b71841c5abc3d742ec13fb16f099d596b781e6f5c7d0b6682b1216a8258" ); @@ -57,7 +57,7 @@ fn test_hash_to_curve() { let hash = Point::hash_to_curve("z.cash:test"); let p: Point = hash(b"hello"); let (x, y, z) = p.jacobian_coordinates(); - println!("{:?}", p); + assert!( format!("{:?}", x) == "0x24c3431db13111fcba2f214a0662ae48e675801988c5705877525750b65f7ad8" );