1 2 3 4 5 6 7 8 9 10 11 12 13 14
// Copyright 2020-2021 IOTA Stiftung // SPDX-License-Identifier: Apache-2.0 use bee_block::rand::bytes::rand_bytes; use bee_pow::providers::NonceProvider; #[test] fn constant_provide() { let bytes = rand_bytes(256); let nonce_1 = 42; let nonce_2 = nonce_1.nonce(&bytes[0..248], 4000).unwrap(); assert_eq!(nonce_1, nonce_2); }