From f0d5406d0bbb8bfa09fc7f662f18ada244936d42 Mon Sep 17 00:00:00 2001 From: Ignotus Peverell Date: Sat, 30 Jun 2018 05:07:24 +0100 Subject: [PATCH] Fix cuckoo20 sizeshift in test --- core/src/pow/cuckoo.rs | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/core/src/pow/cuckoo.rs b/core/src/pow/cuckoo.rs index 757451b09..41317e219 100644 --- a/core/src/pow/cuckoo.rs +++ b/core/src/pow/cuckoo.rs @@ -352,17 +352,23 @@ mod test { let nonces1 = Miner::from_hash(blake2(&[49]).as_bytes(), 75, 42, 20) .mine() .unwrap(); - assert_eq!(Proof::new(V1.to_vec()), nonces1); + let mut proof = Proof::new(V1.to_vec()); + proof.cuckoo_sizeshift = 20; + assert_eq!(proof, nonces1); let nonces2 = Miner::from_hash(blake2(&[50]).as_bytes(), 70, 42, 20) .mine() .unwrap(); - assert_eq!(Proof::new(V2.to_vec()), nonces2); + let mut proof = Proof::new(V2.to_vec()); + proof.cuckoo_sizeshift = 20; + assert_eq!(proof, nonces2); let nonces3 = Miner::from_hash(blake2(&[51]).as_bytes(), 70, 42, 20) .mine() .unwrap(); - assert_eq!(Proof::new(V3.to_vec()), nonces3); + let mut proof = Proof::new(V3.to_vec()); + proof.cuckoo_sizeshift = 20; + assert_eq!(proof, nonces3); } #[test]