Skip to content

Commit

Permalink
Fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
davxy committed Jul 9, 2024
1 parent a13ad4e commit 99f8984
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -265,12 +265,14 @@ mod tests {
};

#[test]
fn proof_to_hash_works() {
fn vrf_output_check() {
use ark_std::rand::SeedableRng;
let mut rng = rand_chacha::ChaCha20Rng::from_seed([42; 32]);
let secret = Secret::from_seed(TEST_SEED);
let input = Input::from(random_val(None));
let input = Input::from(random_val(Some(&mut rng)));
let output = secret.output(input);

let expected = "2eaa1a349197bb2b6c455bc5554b331162f0e9b13aea0aab28283cc30e7c6482";
let expected = "0245a793d85347ca3c056f8c8f42f1049a310fabff6933b9eae592541a545cb8";
assert_eq!(expected, hex::encode(output.hash()));
}
}

0 comments on commit 99f8984

Please sign in to comment.