Changeset View
Changeset View
Standalone View
Standalone View
test/functional/mempool_spend_coinbase.py
Show All 15 Lines | |||||
from test_framework.blocktools import create_raw_transaction | from test_framework.blocktools import create_raw_transaction | ||||
from test_framework.util import assert_equal, assert_raises_rpc_error | from test_framework.util import assert_equal, assert_raises_rpc_error | ||||
class MempoolSpendCoinbaseTest(BitcoinTestFramework): | class MempoolSpendCoinbaseTest(BitcoinTestFramework): | ||||
def set_test_params(self): | def set_test_params(self): | ||||
self.num_nodes = 1 | self.num_nodes = 1 | ||||
def skip_test_if_missing_module(self): | |||||
self.skip_if_no_wallet() | |||||
def run_test(self): | def run_test(self): | ||||
chain_height = self.nodes[0].getblockcount() | chain_height = self.nodes[0].getblockcount() | ||||
assert_equal(chain_height, 200) | assert_equal(chain_height, 200) | ||||
node0_address = self.nodes[0].getnewaddress() | node0_address = self.nodes[0].getnewaddress() | ||||
# Coinbase at height chain_height-100+1 ok in mempool, should | # Coinbase at height chain_height-100+1 ok in mempool, should | ||||
# get mined. Coinbase at height chain_height-100+2 is | # get mined. Coinbase at height chain_height-100+2 is | ||||
# is too immature to spend. | # is too immature to spend. | ||||
Show All 25 Lines |