Position PoW.MinDifficultyRules test after rule activates

This commit is contained in:
Jack Grigg 2018-10-04 23:46:50 +01:00
parent 4c90270469
commit 2b47b0de7d
No known key found for this signature in database
GPG Key ID: 1B8D649257DB0829
1 changed files with 1 additions and 1 deletions

View File

@ -79,7 +79,7 @@ TEST(PoW, MinDifficultyRules) {
std::vector<CBlockIndex> blocks(lastBlk+1);
for (int i = 0; i <= lastBlk; i++) {
blocks[i].pprev = i ? &blocks[i - 1] : nullptr;
blocks[i].nHeight = i;
blocks[i].nHeight = params.nPowAllowMinDifficultyBlocksAfterHeight.get() + i;
blocks[i].nTime = 1269211443 + i * params.nPowTargetSpacing;
blocks[i].nBits = 0x1e7fffff; /* target 0x007fffff000... */
blocks[i].nChainWork = i ? blocks[i - 1].nChainWork + GetBlockProof(blocks[i - 1]) : arith_uint256(0);