Skip to content

Commit

Permalink
rebased
Browse files Browse the repository at this point in the history
  • Loading branch information
stackman27 committed Apr 24, 2023
1 parent ffbae7d commit 94c0046
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions x/concentrated-liquidity/simulation/sim_msgs.go
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ func RandomMsgCreateConcentratedPool(k clkeeper.Keeper, sim *osmosimtypes.SimCtx
// make sure the denoms are valid authorized quote denoms

defaultParams := cltypes.DefaultParams()
defaultParams.IsPermissionlessPoolCreationEnabled = true
defaultParams.AuthorizedQuoteDenoms = append(defaultParams.AuthorizedQuoteDenoms, coin1.Denom, coin0.Denom)

k.SetParams(ctx, defaultParams)
Expand Down Expand Up @@ -89,6 +90,9 @@ func RandMsgWithdrawPosition(k clkeeper.Keeper, sim *osmosimtypes.SimCtx, ctx sd
}

withdrawAmount := sim.RandomDecAmount(position.Liquidity)
if withdrawAmount.LT(sdk.ZeroDec()) {
return nil, fmt.Errorf("Invalid withdraw Amount")
}

return &cltypes.MsgWithdrawPosition{
PositionId: position.PositionId,
Expand Down

0 comments on commit 94c0046

Please sign in to comment.