Skip to content

Commit

Permalink
fix: import-export simulation
Browse files Browse the repository at this point in the history
  • Loading branch information
poorphd committed Aug 23, 2023
1 parent c09fe06 commit 513900c
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
4 changes: 3 additions & 1 deletion app/sim_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,9 @@ func TestAppImportExport(t *testing.T) {
},
},
{app.keys[distrtypes.StoreKey], newApp.keys[distrtypes.StoreKey], [][]byte{}},
{app.keys[paramstypes.StoreKey], newApp.keys[paramstypes.StoreKey], [][]byte{}},
{app.keys[paramstypes.StoreKey], newApp.keys[paramstypes.StoreKey], [][]byte{
[]byte("evm/EnableExtraEIPs"),
}},
{app.keys[evidencetypes.StoreKey], newApp.keys[evidencetypes.StoreKey], [][]byte{}},
{app.keys[capabilitytypes.StoreKey], newApp.keys[capabilitytypes.StoreKey], [][]byte{}},
{app.keys[feegrant.StoreKey], newApp.keys[feegrant.StoreKey], [][]byte{}},
Expand Down
2 changes: 0 additions & 2 deletions x/govshuttle/module_simulation.go
Original file line number Diff line number Diff line change
Expand Up @@ -37,14 +37,12 @@ func (am AppModule) ProposalContents(_ module.SimulationState) []simtypes.Weight

// RandomizedParams creates randomized param changes for the simulator
func (am AppModule) RandomizedParams(_ *rand.Rand) []simtypes.ParamChange {

return []simtypes.ParamChange{}
}

// RegisterStoreDecoder registers a decoder
func (am AppModule) RegisterStoreDecoder(sdr sdk.StoreDecoderRegistry) {
sdr[types.StoreKey] = simulation.NewDecodeStore(am.cdc)

}

// WeightedOperations returns the all the gov module operations with their respective weights.
Expand Down
2 changes: 1 addition & 1 deletion x/govshuttle/simulation/decoder.go
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ import (
func NewDecodeStore(cdc codec.Codec) func(kvA, kvB kv.Pair) string {
return func(kvA, kvB kv.Pair) string {
switch {
case bytes.Equal(kvA.Key[:], types.PortKey):
case bytes.Equal(kvA.Key[:4], types.PortKey):
var paA, paB common.Address
paA = common.BytesToAddress(kvA.Value)
paB = common.BytesToAddress(kvB.Value)
Expand Down

0 comments on commit 513900c

Please sign in to comment.