[Bitcoin-development] Question on creating test cases for block.CheckBlock()
sergiolerner at certimix.com
Mon Jul 21 17:30:34 UTC 2014
I'm working on a BIP which needs to modify the block acceptance rules. I
have two ways of testing:
- Mining blocks on the testnet
- Creating test cases for Bitcoin Core.
I want to create those test cases for block.CheckBlock(), which involves
verifying 100 dynamically generated blocks.
What is the state of the blockchain when a test case is executed ? Is is
configured for the regtest, testnet3 or mainnet? What blocks are in the
blockchain? Only the genesis block?
checkblock_tests.cpp seems to be the only test case for CheckBlock() and
it assumes the mainnet is configured.
I need to use the regtest so I can create blocks of difficulty 1.
Best regards and thank you in advance,
More information about the bitcoin-dev