github.com/fibonacci-chain/fbc@v0.0.0-20231124064014-c7636198c1e9/libs/cosmos-sdk/x/mint/simulation/params.go (about) 1 package simulation 2 3 // DONTCOVER 4 5 import ( 6 "fmt" 7 "math/rand" 8 9 "github.com/fibonacci-chain/fbc/libs/cosmos-sdk/x/mint/internal/types" 10 "github.com/fibonacci-chain/fbc/libs/cosmos-sdk/x/simulation" 11 ) 12 13 const ( 14 keyInflationRateChange = "InflationRateChange" 15 keyInflationMax = "InflationMax" 16 keyInflationMin = "InflationMin" 17 keyGoalBonded = "GoalBonded" 18 ) 19 20 // ParamChanges defines the parameters that can be modified by param change proposals 21 // on the simulation 22 func ParamChanges(r *rand.Rand) []simulation.ParamChange { 23 return []simulation.ParamChange{ 24 simulation.NewSimParamChange(types.ModuleName, keyInflationRateChange, 25 func(r *rand.Rand) string { 26 return fmt.Sprintf("\"%s\"", GenInflationRateChange(r)) 27 }, 28 ), 29 simulation.NewSimParamChange(types.ModuleName, keyInflationMax, 30 func(r *rand.Rand) string { 31 return fmt.Sprintf("\"%s\"", GenInflationMax(r)) 32 }, 33 ), 34 simulation.NewSimParamChange(types.ModuleName, keyInflationMin, 35 func(r *rand.Rand) string { 36 return fmt.Sprintf("\"%s\"", GenInflationMin(r)) 37 }, 38 ), 39 simulation.NewSimParamChange(types.ModuleName, keyGoalBonded, 40 func(r *rand.Rand) string { 41 return fmt.Sprintf("\"%s\"", GenGoalBonded(r)) 42 }, 43 ), 44 } 45 }