aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMarcoFalke <falke.marco@gmail.com>2019-07-03 20:46:43 +0700
committerMarcoFalke <falke.marco@gmail.com>2019-12-20 22:24:17 +0700
commit6666ef13f167cfe880c2e94c09d003594d010cf3 (patch)
tree3e16e90f3f20eee3c6d5831c898196ce46e95d70
parent3e949380725ca32be6c9812a926727b0a45723a9 (diff)
test: Properly document blockinfo size in miner_tests
This fixes a typo in the test documentation
-rw-r--r--src/test/miner_tests.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/test/miner_tests.cpp b/src/test/miner_tests.cpp
index d79a598bf1..2b08e6a36c 100644
--- a/src/test/miner_tests.cpp
+++ b/src/test/miner_tests.cpp
@@ -56,8 +56,7 @@ static BlockAssembler AssemblerForTest(const CChainParams& params) {
return BlockAssembler(params, options);
}
-static
-struct {
+constexpr static struct {
unsigned char extranonce;
unsigned int nonce;
} blockinfo[] = {
@@ -225,7 +224,8 @@ BOOST_AUTO_TEST_CASE(CreateNewBlock_validity)
BOOST_CHECK(pblocktemplate = AssemblerForTest(chainparams).CreateNewBlock(scriptPubKey));
// We can't make transactions until we have inputs
- // Therefore, load 100 blocks :)
+ // Therefore, load 110 blocks :)
+ static_assert(sizeof(blockinfo) / sizeof(*blockinfo) == 110, "Should have 110 blocks to import");
int baseheight = 0;
std::vector<CTransactionRef> txFirst;
for (unsigned int i = 0; i < sizeof(blockinfo)/sizeof(*blockinfo); ++i)