parent
6dd7049339
commit
60d4ae52f7
@ -1667,6 +1667,25 @@ class Decred(Coin):
|
||||
return h
|
||||
|
||||
|
||||
class DecredTestnet(Decred):
|
||||
SHORTNAME = "tDCR"
|
||||
NET = "testnet"
|
||||
XPUB_VERBYTES = bytes.fromhex("043587d1")
|
||||
XPRV_VERBYTES = bytes.fromhex("04358397")
|
||||
P2PKH_VERBYTE = bytes.fromhex("0f21")
|
||||
P2SH_VERBYTES = [bytes.fromhex("0efc")]
|
||||
WIF_BYTE = bytes.fromhex("22de")
|
||||
GENESIS_HASH = (
|
||||
'4261602a9d07d80ad47621a64ba6a07754902e496777edc4ff581946bd7bc29c')
|
||||
BASIC_HEADER_SIZE = 180
|
||||
ALLOW_ADVANCING_ERRORS = True
|
||||
TX_COUNT = 217380620
|
||||
TX_COUNT_HEIGHT = 464000
|
||||
TX_PER_BLOCK = 1800
|
||||
REORG_LIMIT = 1000
|
||||
RPC_PORT = 19109
|
||||
|
||||
|
||||
class Axe(Dash):
|
||||
NAME = "Axe"
|
||||
SHORTNAME = "AXE"
|
||||
|
||||
24
tests/blocks/decred_testnet_1000.json
Normal file
24
tests/blocks/decred_testnet_1000.json
Normal file
File diff suppressed because one or more lines are too long
23
tests/blocks/decred_testnet_5107.json
Normal file
23
tests/blocks/decred_testnet_5107.json
Normal file
File diff suppressed because one or more lines are too long
@ -113,6 +113,13 @@ def test_COIN_NET():
|
||||
e = Env()
|
||||
assert e.coin == lib_coins.BitcoinGoldRegtest
|
||||
os.environ.pop('NET')
|
||||
os.environ['COIN'] = ' Decred '
|
||||
e = Env()
|
||||
assert e.coin == lib_coins.Decred
|
||||
os.environ['NET'] = 'testnet'
|
||||
e = Env()
|
||||
assert e.coin == lib_coins.DecredTestnet
|
||||
os.environ.pop('NET')
|
||||
os.environ['COIN'] = ' BitcoinGreen '
|
||||
e = Env()
|
||||
assert e.coin == lib_coins.Bitg
|
||||
|
||||
@ -69,7 +69,8 @@ def test_block(block_details):
|
||||
assert block_info['nonce'] == h['nonce']
|
||||
assert block_info['bits'] == pack_be_uint32(h['bits']).hex()
|
||||
|
||||
assert coin.header_hash(block.header) == hex_str_to_hash(block_info['hash'])
|
||||
assert coin.header_hash(
|
||||
block.header) == hex_str_to_hash(block_info['hash'])
|
||||
assert (coin.header_prevhash(block.header)
|
||||
== hex_str_to_hash(block_info['previousblockhash']))
|
||||
for n, (tx, txid) in enumerate(block.transactions):
|
||||
|
||||
Loading…
Reference in New Issue
Block a user