diff --git a/accounts/abi/bind/backends/simulated.go b/accounts/abi/bind/backends/simulated.go index 441849c20f..d7c74f65fe 100644 --- a/accounts/abi/bind/backends/simulated.go +++ b/accounts/abi/bind/backends/simulated.go @@ -79,7 +79,7 @@ type SimulatedBackend struct { // A simulated backend always uses chainID 1337. func NewSimulatedBackendWithDatabase(database ethdb.Database, alloc core.GenesisAlloc, gasLimit uint64) *SimulatedBackend { genesis := core.Genesis{ - Config: params.AllEthashProtocolChanges, + Config: params.BorUnittestChainConfig, GasLimit: gasLimit, Alloc: alloc, } diff --git a/core/chain_makers.go b/core/chain_makers.go index ab35f5f67f..3c43c9d86a 100644 --- a/core/chain_makers.go +++ b/core/chain_makers.go @@ -135,15 +135,6 @@ func (b *BlockGen) AddTx(tx *types.Transaction) { // the block in chain will be returned. func (b *BlockGen) AddTxWithChain(bc *BlockChain, tx *types.Transaction) { b.addTx(bc, vm.Config{}, tx) - b.statedb.SetTxContext(tx.Hash(), len(b.txs)) - - receipt, err := ApplyTransaction(b.config, bc, &b.header.Coinbase, b.gasPool, b.statedb, b.header, tx, &b.header.GasUsed, vm.Config{}, nil) - if err != nil { - panic(err) - } - - b.txs = append(b.txs, tx) - b.receipts = append(b.receipts, receipt) } // AddTxWithVMConfig adds a transaction to the generated block. If no coinbase has diff --git a/core/state_transition.go b/core/state_transition.go index 89d572bebf..95e668abe0 100644 --- a/core/state_transition.go +++ b/core/state_transition.go @@ -459,7 +459,7 @@ func (st *StateTransition) TransitionDb(interruptCtx context.Context) (*Executio if rules.IsLondon { burntContractAddress := common.HexToAddress(st.evm.ChainConfig().Bor.CalculateBurntContract(st.evm.Context.BlockNumber.Uint64())) - burnAmount := new(big.Int).Mul(new(big.Int).SetUint64(st.gasUsed()), st.evm.Context.BaseFee) + burnAmount = new(big.Int).Mul(new(big.Int).SetUint64(st.gasUsed()), st.evm.Context.BaseFee) if !st.noFeeBurnAndTip { st.state.AddBalance(burntContractAddress, burnAmount)