Skip to content

Commit

Permalink
core: fix uncle creation in TestFastVsFullChains (#25476)
Browse files Browse the repository at this point in the history
Co-authored-by: Felix Lange <fjl@twurst.com>
  • Loading branch information
int88 and fjl authored Aug 8, 2022
1 parent e93442c commit e4b3bd6
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions core/blockchain_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -759,9 +759,9 @@ func TestFastVsFullChains(t *testing.T) {
block.AddTx(tx)
}
}
// If the block number is a multiple of 5, add a few bonus uncles to the block
if i%5 == 5 {
block.AddUncle(&types.Header{ParentHash: block.PrevBlock(i - 1).Hash(), Number: big.NewInt(int64(i - 1))})
// If the block number is a multiple of 5, add an uncle to the block
if i%5 == 4 {
block.AddUncle(&types.Header{ParentHash: block.PrevBlock(i - 2).Hash(), Number: big.NewInt(int64(i))})
}
})
// Import the chain as an archive node for the comparison baseline
Expand Down

0 comments on commit e4b3bd6

Please sign in to comment.