Tweak the hash_to_point test

It ran for too long and had a "test_" prefix not shared with other 
tests.
This commit is contained in:
Luke Parker 2022-07-13 02:48:36 -04:00
parent a1599df126
commit 95a4101a9a
No known key found for this signature in database
GPG key ID: F9F1386DB1E119B6

View file

@ -2,12 +2,12 @@ use rand::rngs::OsRng;
use curve25519_dalek::constants::ED25519_BASEPOINT_TABLE;
use crate::{random_scalar, ringct::hash_to_point::{hash_to_point, rust_hash_to_point}};
use crate::{random_scalar, ringct::hash_to_point::{hash_to_point as c_hash_to_point, rust_hash_to_point}};
#[test]
fn test_hash_to_point() {
for _ in 0 .. 200 {
fn hash_to_point() {
for _ in 0 .. 50 {
let point = &random_scalar(&mut OsRng) * &ED25519_BASEPOINT_TABLE;
assert_eq!(rust_hash_to_point(point), hash_to_point(point));
assert_eq!(rust_hash_to_point(point), c_hash_to_point(point));
}
}