mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-01-26 11:13:23 -03:00
test: use 327 fewer blocks in feature_nulldummy
by generating 100 blocks for coinbase maturity instead of 427. This speeds up the test and should help avoid timeout errors.
This commit is contained in:
parent
68c280f197
commit
ccd976dd3d
1 changed files with 3 additions and 3 deletions
|
@ -20,14 +20,14 @@ from test_framework.script import CScript
|
||||||
from test_framework.test_framework import BitcoinTestFramework
|
from test_framework.test_framework import BitcoinTestFramework
|
||||||
from test_framework.util import assert_equal, assert_raises_rpc_error
|
from test_framework.util import assert_equal, assert_raises_rpc_error
|
||||||
|
|
||||||
COINBASE_MATURITY = 427
|
COINBASE_MATURITY = 100
|
||||||
NULLDUMMY_ERROR = "non-mandatory-script-verify-flag (Dummy CHECKMULTISIG argument must be zero)"
|
NULLDUMMY_ERROR = "non-mandatory-script-verify-flag (Dummy CHECKMULTISIG argument must be zero)"
|
||||||
|
|
||||||
def trueDummy(tx):
|
def trueDummy(tx):
|
||||||
scriptSig = CScript(tx.vin[0].scriptSig)
|
scriptSig = CScript(tx.vin[0].scriptSig)
|
||||||
newscript = []
|
newscript = []
|
||||||
for i in scriptSig:
|
for i in scriptSig:
|
||||||
if (len(newscript) == 0):
|
if len(newscript) == 0:
|
||||||
assert len(i) == 0
|
assert len(i) == 0
|
||||||
newscript.append(b'\x51')
|
newscript.append(b'\x51')
|
||||||
else:
|
else:
|
||||||
|
@ -38,7 +38,7 @@ def trueDummy(tx):
|
||||||
class NULLDUMMYTest(BitcoinTestFramework):
|
class NULLDUMMYTest(BitcoinTestFramework):
|
||||||
|
|
||||||
def set_test_params(self):
|
def set_test_params(self):
|
||||||
# Need two nodes only so GBT doesn't complain that it's not connected
|
# Need two nodes so GBT (getblocktemplate) doesn't complain that it's not connected.
|
||||||
self.num_nodes = 2
|
self.num_nodes = 2
|
||||||
self.setup_clean_chain = True
|
self.setup_clean_chain = True
|
||||||
# This script tests NULLDUMMY activation, which is part of the 'segwit' deployment, so we go through
|
# This script tests NULLDUMMY activation, which is part of the 'segwit' deployment, so we go through
|
||||||
|
|
Loading…
Add table
Reference in a new issue