-
Notifications
You must be signed in to change notification settings - Fork 734
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: update x/bank blocked addresses (#1493)
* updates * updates * updates * updates Co-authored-by: lg <[email protected]>
- Loading branch information
1 parent
d4ca7fc
commit 374472f
Showing
2 changed files
with
53 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
package gaia_test | ||
|
||
import ( | ||
"testing" | ||
|
||
authtypes "github.com/cosmos/cosmos-sdk/x/auth/types" | ||
govtypes "github.com/cosmos/cosmos-sdk/x/gov/types" | ||
"github.com/stretchr/testify/require" | ||
"github.com/tendermint/tendermint/libs/log" | ||
db "github.com/tendermint/tm-db" | ||
|
||
gaia "github.com/cosmos/gaia/v7/app" | ||
) | ||
|
||
type EmptyAppOptions struct{} | ||
|
||
func (ao EmptyAppOptions) Get(o string) interface{} { | ||
return nil | ||
} | ||
|
||
func TestGaiaApp_BlockedModuleAccountAddrs(t *testing.T) { | ||
app := gaia.NewGaiaApp( | ||
log.NewNopLogger(), | ||
db.NewMemDB(), | ||
nil, | ||
true, | ||
map[int64]bool{}, | ||
gaia.DefaultNodeHome, | ||
0, | ||
gaia.MakeEncodingConfig(), | ||
EmptyAppOptions{}, | ||
) | ||
blockedAddrs := app.BlockedModuleAccountAddrs() | ||
|
||
// TODO: Blocked on updating to v0.46.x | ||
// require.NotContains(t, blockedAddrs, authtypes.NewModuleAddress(grouptypes.ModuleName).String()) | ||
require.NotContains(t, blockedAddrs, authtypes.NewModuleAddress(govtypes.ModuleName).String()) | ||
} |