Fix doc test.

This commit is contained in:
Gav Wood 2016-06-27 19:16:26 +02:00
parent 2a51a30d41
commit a102015ecf
3 changed files with 6 additions and 4 deletions

View File

@ -133,8 +133,8 @@ Sealing/Mining Options:
NOTE: MINING WILL NOT WORK WITHOUT THIS OPTION. NOTE: MINING WILL NOT WORK WITHOUT THIS OPTION.
--force-sealing Force the node to author new blocks as if it were --force-sealing Force the node to author new blocks as if it were
always sealing/mining. always sealing/mining.
--reseal-on-txs Specify which transactions should force the node --reseal-on-txs SET Specify which transactions should force the node
to reseal a block. One of: to reseal a block. SET is one of:
none - never reseal on new transactions; none - never reseal on new transactions;
own - reseal only on a new local transaction; own - reseal only on a new local transaction;
ext - reseal only on a new external transaction; ext - reseal only on a new external transaction;

View File

@ -24,7 +24,7 @@ use ethcore::spec::{Genesis, Spec};
use ethcore::block::Block; use ethcore::block::Block;
use ethcore::views::BlockView; use ethcore::views::BlockView;
use ethcore::ethereum; use ethcore::ethereum;
use ethcore::miner::{MinerOptions, MinerService, ExternalMiner, Miner}; use ethcore::miner::{MinerOptions, MinerService, ExternalMiner, Miner, PendingSet};
use ethcore::account_provider::AccountProvider; use ethcore::account_provider::AccountProvider;
use devtools::RandomTempPath; use devtools::RandomTempPath;
use util::Hashable; use util::Hashable;
@ -54,6 +54,8 @@ fn miner_service(spec: Spec, accounts: Arc<AccountProvider>) -> Arc<Miner> {
force_sealing: true, force_sealing: true,
reseal_on_external_tx: true, reseal_on_external_tx: true,
reseal_on_own_tx: true, reseal_on_own_tx: true,
max_tx_gas: None,
pending_set: PendingSet::SealingOrElseQueue,
}, },
spec, spec,
Some(accounts) Some(accounts)

View File

@ -44,7 +44,7 @@
//! let mut service = NetworkService::new(NetworkConfiguration::new()).unwrap(); //! let mut service = NetworkService::new(NetworkConfiguration::new()).unwrap();
//! service.start().unwrap(); //! service.start().unwrap();
//! let dir = env::temp_dir(); //! let dir = env::temp_dir();
//! let miner = Miner::new(MinerOptions::default(), ethereum::new_frontier(true), None); //! let miner = Miner::new(Default::default(), ethereum::new_frontier(true), None);
//! let client = Client::new( //! let client = Client::new(
//! ClientConfig::default(), //! ClientConfig::default(),
//! ethereum::new_frontier(true), //! ethereum::new_frontier(true),