From 497d66e482235ed671e27c531064b91d6f1230c5 Mon Sep 17 00:00:00 2001 From: Yeastplume Date: Wed, 3 Oct 2018 12:18:23 +0100 Subject: [PATCH] Pow test fix (#1651) * fix pow testing * rustfmt --- servers/src/mining/test_miner.rs | 11 ++++------- 1 file changed, 4 insertions(+), 7 deletions(-) diff --git a/servers/src/mining/test_miner.rs b/servers/src/mining/test_miner.rs index 5316df3a7..3d4f58f71 100644 --- a/servers/src/mining/test_miner.rs +++ b/servers/src/mining/test_miner.rs @@ -26,8 +26,8 @@ use common::types::StratumServerConfig; use core::core::hash::{Hash, Hashed}; use core::core::verifier_cache::VerifierCache; use core::core::{Block, BlockHeader}; +use core::global; use core::pow::PoWContext; -use core::{consensus, global}; use mining::mine_block; use pool; use util::LOGGER; @@ -96,12 +96,9 @@ impl Miner { let mut iter_count = 0; while head.hash() == *latest_hash && Utc::now().timestamp() < deadline { - let mut ctx = global::create_pow_context::( - global::min_sizeshift(), - global::proofsize(), - consensus::EASINESS, - 10, - ).unwrap(); + let mut ctx = + global::create_pow_context::(global::min_sizeshift(), global::proofsize(), 10) + .unwrap(); ctx.set_header_nonce(b.header.pre_pow(), None, true) .unwrap(); if let Ok(proofs) = ctx.find_cycles() {