Skip to content

Commit

Permalink
chore: commit at the end of benchmark (#5229)
Browse files Browse the repository at this point in the history
* chore: commit at the end of benchmark

* updates
  • Loading branch information
p0mvn authored and pysel committed Jun 6, 2023
1 parent 9129bf6 commit af637af
Showing 1 changed file with 2 additions and 4 deletions.
6 changes: 2 additions & 4 deletions x/concentrated-liquidity/bench_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import (
"math"
"math/rand"
"testing"
"time"

"github.com/cosmos/cosmos-sdk/simapp"
sdk "github.com/cosmos/cosmos-sdk/types"
Expand Down Expand Up @@ -220,9 +219,8 @@ func BenchmarkSwapExactAmountIn(b *testing.B) {
fmt.Println("num_ticks_traversed", len(liquidityNet))
fmt.Println("current_tick", currentTick)

// Increase block time so that some incentives uptime accumulator update logic
// isn't a no-op.
s.Ctx = s.Ctx.WithBlockTime(s.Ctx.BlockTime().Add(time.Second))
// Commit the block so that position updates are propagated to IAVL.
s.Commit()

// Fund swap amount.
simapp.FundAccount(s.App.BankKeeper, s.Ctx, s.TestAccs[0], sdk.NewCoins(largeSwapInCoin))
Expand Down

0 comments on commit af637af

Please sign in to comment.