Skip to content

Commit

Permalink
nit refundAmt to refundAmount
Browse files Browse the repository at this point in the history
  • Loading branch information
jinmel committed Mar 13, 2024
1 parent 540e701 commit fa29c8f
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions miner/builder_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -219,17 +219,17 @@ func TestBuilder_AddBundles_MevShare(t *testing.T) {

res, err = builder.AddBundles([]*suavextypes.Bundle{bundle})
refundTransferCost := new(big.Int).Mul(big.NewInt(28000), builder.env.header.BaseFee)
refundAmt := new(big.Int).Mul(bundleProfit, big.NewInt(int64(refundPercent)))
refundAmt = new(big.Int).Div(refundAmt, big.NewInt(100))
refundAmt = new(big.Int).Sub(refundAmt, refundTransferCost)
refundAmount := new(big.Int).Mul(bundleProfit, big.NewInt(int64(refundPercent)))
refundAmount = new(big.Int).Div(refundAmount, big.NewInt(100))
refundAmount = new(big.Int).Sub(refundAmount, refundTransferCost)

require.NoError(t, err)
require.Len(t, res, 1)
require.True(t, res[0].Success)
require.Len(t, res[0].SimulateTransactionResults, 2)
require.Len(t, builder.env.txs, 5) // 1 additional refund paymentTx
paymentTx := builder.env.txs[4]
require.Equal(t, refundAmt, paymentTx.Value())
require.Equal(t, refundAmount, paymentTx.Value())
}

func TestBuilder_FillTransactions(t *testing.T) {
Expand Down

0 comments on commit fa29c8f

Please sign in to comment.