mirror of
https://github.com/vacp2p/zerokit.git
synced 2025-01-19 02:52:08 +00:00
55b00fd653
* to color_eyre::Result 1st part * tests and seconds batch * third batch * rln fixes + multiplier * rln-wasm, assert rln, multiplier * io to color_eyre * fmt + clippy * fix lint * temporary fix of `ark-circom` * fix ci after merge * fmt * fix rln tests * minor * fix tests * imports * requested change * report + commented line + requested change * requested changes * fix build * lint fixes * better comments --------- Co-authored-by: tyshkor <tyshko1@gmail.com>
22 lines
474 B
Rust
22 lines
474 B
Rust
#[cfg(test)]
|
|
mod tests {
|
|
use multiplier::public::Multiplier;
|
|
|
|
#[test]
|
|
fn multiplier_proof() {
|
|
let mul = Multiplier::new().unwrap();
|
|
|
|
let mut output_data: Vec<u8> = Vec::new();
|
|
let _ = mul.prove(&mut output_data);
|
|
|
|
let proof_data = &output_data[..];
|
|
|
|
// XXX Pass as arg?
|
|
//let pvk = prepare_verifying_key(&mul.params.vk);
|
|
|
|
let verified = mul.verify(proof_data).unwrap();
|
|
|
|
assert!(verified);
|
|
}
|
|
}
|