Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 13 additions & 2 deletions smite-scenarios/src/targets/bitcoind.rs
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,19 @@ use smite::process::ManagedProcess;

use super::TargetError;

/// Number of blocks to generate at startup for coinbase maturity.
pub const INITIAL_BLOCKS: u64 = 101;
/// Blocks a coinbase output must be buried under before the wallet spends it.
const COINBASE_MATURITY: u64 = 100;

/// Mature coinbase outputs the wallet holds after startup.
///
/// Funding a transaction locks the coins it selects, so a program that funds
/// several transactions needs several coins, and mining them here means it
/// never has to mine blocks during execution to get them.
const SPENDABLE_UTXOS: u64 = 16;

/// Number of blocks to generate at startup, each paying its coinbase to the
/// wallet.
pub const INITIAL_BLOCKS: u64 = COINBASE_MATURITY + SPENDABLE_UTXOS;

/// Bitcoind configuration.
pub struct BitcoindConfig {
Expand Down
Loading