fix: remove newly introduced simapp dependency (#13219)
This commit is contained in:
parent
1bccc54d91
commit
5912f75a7d
1
go.mod
1
go.mod
|
@ -8,7 +8,6 @@ require (
|
||||||
cosmossdk.io/depinject v1.0.0-alpha.2
|
cosmossdk.io/depinject v1.0.0-alpha.2
|
||||||
cosmossdk.io/errors v1.0.0-beta.7
|
cosmossdk.io/errors v1.0.0-beta.7
|
||||||
cosmossdk.io/math v1.0.0-beta.3
|
cosmossdk.io/math v1.0.0-beta.3
|
||||||
cosmossdk.io/simapp v0.0.0-20220908203654-84d4bf5accad
|
|
||||||
github.com/99designs/keyring v1.2.1
|
github.com/99designs/keyring v1.2.1
|
||||||
github.com/armon/go-metrics v0.4.1
|
github.com/armon/go-metrics v0.4.1
|
||||||
github.com/bgentry/speakeasy v0.1.0
|
github.com/bgentry/speakeasy v0.1.0
|
||||||
|
|
2
go.sum
2
go.sum
|
@ -67,8 +67,6 @@ cosmossdk.io/errors v1.0.0-beta.7 h1:gypHW76pTQGVnHKo6QBkb4yFOJjC+sUGRc5Al3Odj1w
|
||||||
cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE=
|
cosmossdk.io/errors v1.0.0-beta.7/go.mod h1:mz6FQMJRku4bY7aqS/Gwfcmr/ue91roMEKAmDUDpBfE=
|
||||||
cosmossdk.io/math v1.0.0-beta.3 h1:TbZxSopz2LqjJ7aXYfn7nJSb8vNaBklW6BLpcei1qwM=
|
cosmossdk.io/math v1.0.0-beta.3 h1:TbZxSopz2LqjJ7aXYfn7nJSb8vNaBklW6BLpcei1qwM=
|
||||||
cosmossdk.io/math v1.0.0-beta.3/go.mod h1:3LYasri3Zna4XpbrTNdKsWmD5fHHkaNAod/mNT9XdE4=
|
cosmossdk.io/math v1.0.0-beta.3/go.mod h1:3LYasri3Zna4XpbrTNdKsWmD5fHHkaNAod/mNT9XdE4=
|
||||||
cosmossdk.io/simapp v0.0.0-20220908203654-84d4bf5accad h1:5y0F7FHvbJ/uE8L2Ab+0AtKvy5nUyFfxPEAAIy62T/Y=
|
|
||||||
cosmossdk.io/simapp v0.0.0-20220908203654-84d4bf5accad/go.mod h1://fc0lbQ4/I2Gm2xQkzq1U6SjZP+UMomSBFw/nodk9U=
|
|
||||||
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
|
dmitri.shuralyov.com/gpu/mtl v0.0.0-20190408044501-666a987793e9/go.mod h1:H6x//7gZCb22OMCxBHrMx7a5I7Hp++hsVxbQ4BYO7hU=
|
||||||
filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU=
|
filippo.io/edwards25519 v1.0.0-rc.1 h1:m0VOOB23frXZvAOK44usCgLWvtsxIoMCTBGJZlpmGfU=
|
||||||
filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns=
|
filippo.io/edwards25519 v1.0.0-rc.1/go.mod h1:N1IkdkCkiLB6tki+MYJoSx2JTY9NUlxZE7eHn5EwJns=
|
||||||
|
|
|
@ -7,7 +7,6 @@ import (
|
||||||
"github.com/stretchr/testify/require"
|
"github.com/stretchr/testify/require"
|
||||||
tmproto "github.com/tendermint/tendermint/proto/tendermint/types"
|
tmproto "github.com/tendermint/tendermint/proto/tendermint/types"
|
||||||
|
|
||||||
"cosmossdk.io/simapp"
|
|
||||||
"github.com/cosmos/cosmos-sdk/baseapp"
|
"github.com/cosmos/cosmos-sdk/baseapp"
|
||||||
"github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1"
|
"github.com/cosmos/cosmos-sdk/crypto/keys/secp256k1"
|
||||||
cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types"
|
cryptotypes "github.com/cosmos/cosmos-sdk/crypto/types"
|
||||||
|
@ -22,6 +21,7 @@ import (
|
||||||
bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper"
|
bankkeeper "github.com/cosmos/cosmos-sdk/x/bank/keeper"
|
||||||
"github.com/cosmos/cosmos-sdk/x/bank/testutil"
|
"github.com/cosmos/cosmos-sdk/x/bank/testutil"
|
||||||
"github.com/cosmos/cosmos-sdk/x/bank/types"
|
"github.com/cosmos/cosmos-sdk/x/bank/types"
|
||||||
|
_ "github.com/cosmos/cosmos-sdk/x/gov"
|
||||||
govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"
|
govv1 "github.com/cosmos/cosmos-sdk/x/gov/types/v1"
|
||||||
_ "github.com/cosmos/cosmos-sdk/x/params"
|
_ "github.com/cosmos/cosmos-sdk/x/params"
|
||||||
_ "github.com/cosmos/cosmos-sdk/x/staking"
|
_ "github.com/cosmos/cosmos-sdk/x/staking"
|
||||||
|
@ -109,7 +109,9 @@ func createTestSuite(t *testing.T, genesisAccounts []authtypes.GenesisAccount) s
|
||||||
configurator.AuthModule(),
|
configurator.AuthModule(),
|
||||||
configurator.StakingModule(),
|
configurator.StakingModule(),
|
||||||
configurator.TxModule(),
|
configurator.TxModule(),
|
||||||
configurator.BankModule()),
|
configurator.BankModule(),
|
||||||
|
configurator.GovModule(),
|
||||||
|
),
|
||||||
startupCfg, &res.BankKeeper, &res.AccountKeeper)
|
startupCfg, &res.BankKeeper, &res.AccountKeeper)
|
||||||
|
|
||||||
res.App = app
|
res.App = app
|
||||||
|
@ -340,12 +342,14 @@ func TestMsgMultiSendDependent(t *testing.T) {
|
||||||
|
|
||||||
func TestMsgSetSendEnabled(t *testing.T) {
|
func TestMsgSetSendEnabled(t *testing.T) {
|
||||||
acc1 := authtypes.NewBaseAccountWithAddress(addr1)
|
acc1 := authtypes.NewBaseAccountWithAddress(addr1)
|
||||||
|
|
||||||
genAccs := []authtypes.GenesisAccount{acc1}
|
genAccs := []authtypes.GenesisAccount{acc1}
|
||||||
app := simapp.SetupWithGenesisAccounts(t, genAccs)
|
s := createTestSuite(t, genAccs)
|
||||||
ctx := app.BaseApp.NewContext(false, tmproto.Header{})
|
|
||||||
require.NoError(t, testutil.FundAccount(app.BankKeeper, ctx, addr1, sdk.NewCoins(sdk.NewInt64Coin("foocoin", 101))))
|
ctx := s.App.BaseApp.NewContext(false, tmproto.Header{})
|
||||||
|
require.NoError(t, testutil.FundAccount(s.BankKeeper, ctx, addr1, sdk.NewCoins(sdk.NewInt64Coin("foocoin", 101))))
|
||||||
addr1Str := addr1.String()
|
addr1Str := addr1.String()
|
||||||
govAddr := app.BankKeeper.GetAuthority()
|
govAddr := s.BankKeeper.GetAuthority()
|
||||||
goodGovProp, err := govv1.NewMsgSubmitProposal(
|
goodGovProp, err := govv1.NewMsgSubmitProposal(
|
||||||
[]sdk.Msg{
|
[]sdk.Msg{
|
||||||
types.NewMsgSetSendEnabled(govAddr, nil, nil),
|
types.NewMsgSetSendEnabled(govAddr, nil, nil),
|
||||||
|
@ -423,9 +427,9 @@ func TestMsgSetSendEnabled(t *testing.T) {
|
||||||
|
|
||||||
for _, tc := range testCases {
|
for _, tc := range testCases {
|
||||||
t.Run(tc.desc, func(tt *testing.T) {
|
t.Run(tc.desc, func(tt *testing.T) {
|
||||||
header := tmproto.Header{Height: app.LastBlockHeight() + 1}
|
header := tmproto.Header{Height: s.App.LastBlockHeight() + 1}
|
||||||
txGen := moduletestutil.MakeTestEncodingConfig().TxConfig
|
txGen := moduletestutil.MakeTestEncodingConfig().TxConfig
|
||||||
_, _, err = simtestutil.SignCheckDeliver(tt, txGen, app.BaseApp, header, tc.msgs, "", []uint64{0}, tc.accSeqs, tc.expSimPass, tc.expPass, priv1)
|
_, _, err = simtestutil.SignCheckDeliver(tt, txGen, s.App.BaseApp, header, tc.msgs, "", []uint64{0}, tc.accSeqs, tc.expSimPass, tc.expPass, priv1)
|
||||||
if len(tc.expInError) > 0 {
|
if len(tc.expInError) > 0 {
|
||||||
require.Error(tt, err)
|
require.Error(tt, err)
|
||||||
for _, exp := range tc.expInError {
|
for _, exp := range tc.expInError {
|
||||||
|
|
Loading…
Reference in New Issue