Set withdraw to nil when building blocks for integration tests (#1066)

This commit is contained in:
Jerry 2023-10-30 22:04:20 -07:00 committed by GitHub
parent 5da60c24d7
commit 4896ab25ed
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -220,7 +220,11 @@ func buildNextBlock(t *testing.T, _bor consensus.Engine, chain *core.BlockChain,
ctx := context.Background() ctx := context.Background()
// Finalize and seal the block // Finalize and seal the block
block, _ := _bor.FinalizeAndAssemble(ctx, chain, b.header, state, b.txs, nil, b.receipts, []*types.Withdrawal{}) block, err := _bor.FinalizeAndAssemble(ctx, chain, b.header, state, b.txs, nil, b.receipts, nil)
if err != nil {
panic(fmt.Sprintf("error finalizing block: %v", err))
}
// Write state changes to db // Write state changes to db
root, err := state.Commit(chain.Config().IsEIP158(b.header.Number)) root, err := state.Commit(chain.Config().IsEIP158(b.header.Number))