Update test code

This commit is contained in:
Ethan Frey
2020-06-22 14:00:50 +02:00
parent ac95b583fc
commit cefd743146
3 changed files with 3 additions and 7 deletions

View File

@@ -46,7 +46,8 @@ var (
NewContractInfo = types.NewContractInfo
NewEnv = types.NewEnv
NewWasmCoins = types.NewWasmCoins
CosmosResult = types.CosmosResult
ParseEvents = types.ParseEvents
ResultFromData = types.ResultFromData
DefaultWasmConfig = types.DefaultWasmConfig
InitGenesis = keeper.InitGenesis
ExportGenesis = keeper.ExportGenesis

View File

@@ -125,7 +125,7 @@ func handleExecute(ctx sdk.Context, k Keeper, msg *MsgExecuteContract) (*sdk.Res
)
res.Events = append(events, ourEvent)
return &res, nil
return res, nil
}
func handleMigration(ctx sdk.Context, k Keeper, msg *MsgMigrateContract) (*sdk.Result, error) {

View File

@@ -238,11 +238,6 @@ func (k Keeper) Migrate(ctx sdk.Context, contractAddress sdk.AccAddress, caller
events := types.ParseEvents(res.Log, contractAddress)
ctx.EventManager().EmitEvents(events)
err = k.dispatchMessages(ctx, contractAddress, res.Messages)
if err != nil {
return nil, err
}
contractInfo.UpdateCodeID(ctx, newCodeID)
k.setContractInfo(ctx, contractAddress, contractInfo)