refactor(x/mint)!: use KVStoreService and context.Context (#16179)
This commit is contained in:
@@ -53,7 +53,7 @@ func Example() {
|
||||
|
||||
// here bankkeeper and staking keeper is nil because we are not testing them
|
||||
// subspace is nil because we don't test params (which is legacy anyway)
|
||||
mintKeeper := mintkeeper.NewKeeper(encodingCfg.Codec, keys[minttypes.StoreKey], nil, accountKeeper, nil, authtypes.FeeCollectorName, authority)
|
||||
mintKeeper := mintkeeper.NewKeeper(encodingCfg.Codec, runtime.NewKVStoreService(keys[minttypes.StoreKey]), nil, accountKeeper, nil, authtypes.FeeCollectorName, authority)
|
||||
mintModule := mint.NewAppModule(encodingCfg.Codec, mintKeeper, accountKeeper, nil, nil)
|
||||
|
||||
// create the application and register all the modules from the previous step
|
||||
@@ -98,7 +98,11 @@ func Example() {
|
||||
sdkCtx := sdk.UnwrapSDKContext(integrationApp.Context())
|
||||
|
||||
// we should also check the state of the application
|
||||
got := mintKeeper.GetParams(sdkCtx)
|
||||
got, err := mintKeeper.GetParams(sdkCtx)
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
|
||||
if diff := cmp.Diff(got, params); diff != "" {
|
||||
panic(diff)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user