Merge branch 'master' into client-ipc-refact

This commit is contained in:
NikVolf
2016-06-30 20:32:13 +03:00
34 changed files with 463 additions and 91 deletions

View File

@@ -504,7 +504,7 @@ impl<C, S, M, EM> Eth for EthClient<C, S, M, EM> where
let pow_hash = b.hash();
let target = Ethash::difficulty_to_boundary(b.block().header().difficulty());
let seed_hash = &self.seed_compute.lock().unwrap().get_seedhash(b.block().header().number());
to_value(&(pow_hash, H256::from_slice(&seed_hash[..]), target))
to_value(&(pow_hash, H256::from_slice(&seed_hash[..]), target, &U256::from(b.block().header().number())))
}).unwrap_or(Err(Error::internal_error())) // no work found.
},
_ => Err(Error::invalid_params())

View File

@@ -17,6 +17,7 @@
//! rpc integration tests.
use std::sync::Arc;
use std::str::FromStr;
use std::time::Duration;
use ethcore::client::{BlockChainClient, Client, ClientConfig};
use ethcore::ids::BlockID;
@@ -51,12 +52,16 @@ fn sync_provider() -> Arc<TestSyncProvider> {
fn miner_service(spec: Spec, accounts: Arc<AccountProvider>) -> Arc<Miner> {
Miner::new(
MinerOptions {
new_work_notify: vec![],
force_sealing: true,
reseal_on_external_tx: true,
reseal_on_own_tx: true,
tx_queue_size: 1024,
tx_gas_limit: !U256::zero(),
pending_set: PendingSet::SealingOrElseQueue,
reseal_min_period: Duration::from_secs(0),
work_queue_size: 50,
enable_resubmission: true,
},
spec,
Some(accounts)

View File

@@ -32,7 +32,7 @@ fn client_service() -> Arc<TestBlockChainClient> {
}
fn logger() -> Arc<RotatingLogger> {
Arc::new(RotatingLogger::new("rpc=trace".to_owned()))
Arc::new(RotatingLogger::new("rpc=trace".to_owned(), false))
}
fn settings() -> Arc<NetworkSettings> {