Skip to content

Commit

Permalink
test(perp-cli_test): Grab module acc addr programatically
Browse files Browse the repository at this point in the history
  • Loading branch information
Unique-Divine committed Dec 28, 2023
1 parent e43672a commit d3f0ce3
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions x/perp/v2/client/cli/cli_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (

abcitypes "github.com/cometbft/cometbft/abci/types"
sdk "github.com/cosmos/cosmos-sdk/types"
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types"
bankcli "github.com/cosmos/cosmos-sdk/x/bank/client/cli"
"github.com/stretchr/testify/suite"

Expand Down Expand Up @@ -714,12 +715,14 @@ func (s *IntegrationTestSuite) TestDonateToEcosystemFund() {

s.NoError(s.network.WaitForNextBlock())
resp := new(sdk.Coin)
moduleAccountAddrPerpEF := "nibi1trh2mamq64u4g042zfeevvjk4cukrthvppfnc7"

moduleAccPerpFund := authtypes.NewModuleAddress(
types.PerpFundModuleAccount).String()
s.NoError(
testutilcli.ExecQuery(
s.network.Validators[0].ClientCtx,
bankcli.GetBalancesCmd(),
[]string{moduleAccountAddrPerpEF, "--denom", types.TestingCollateralDenomNUSD},
[]string{moduleAccPerpFund, "--denom", types.TestingCollateralDenomNUSD},
resp,
),
)
Expand Down

0 comments on commit d3f0ce3

Please sign in to comment.