simulation

package
v1.0.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 14, 2020 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

View Source
const (
	OpWeightMsgSend      = "op_weight_msg_send"
	OpWeightMsgMultiSend = "op_weight_msg_multisend"
)

Simulation operation weights constants

View Source
const (
	SendEnabled = "send_enabled"
)

Simulation parameter constants

Variables

This section is empty.

Functions

func GenSendEnabled added in v1.0.0

func GenSendEnabled(r *rand.Rand) bool

GenSendEnabled randomized SendEnabled

func NewDecodeStore added in v1.0.0

func NewDecodeStore(cdc SupplyUnmarshaller) func(kvA, kvB tmkv.Pair) string

NewDecodeStore returns a function closure that unmarshals the KVPair's values to the corresponding types.

func ParamChanges added in v1.0.0

func ParamChanges(r *rand.Rand) []simtypes.ParamChange

ParamChanges defines the parameters that can be modified by param change proposals on the simulation

func RandomGenesisBalances added in v1.0.0

func RandomGenesisBalances(simState *module.SimulationState) []types.Balance

RandomGenesisAccounts returns a slice of account balances. Each account has a balance of simState.InitialStake for sdk.DefaultBondDenom.

func RandomizedGenState added in v1.0.0

func RandomizedGenState(simState *module.SimulationState)

RandomizedGenState generates a random GenesisState for bank

func SimulateMsgMultiSend added in v1.0.0

func SimulateMsgMultiSend(ak types.AccountKeeper, bk keeper.Keeper) simtypes.Operation

SimulateMsgMultiSend tests and runs a single msg multisend, with randomized, capped number of inputs/outputs. all accounts in msg fields exist in state

func SimulateMsgSend added in v1.0.0

func SimulateMsgSend(ak types.AccountKeeper, bk keeper.Keeper) simtypes.Operation

SimulateMsgSend tests and runs a single msg send where both accounts already exist.

func WeightedOperations added in v1.0.0

func WeightedOperations(
	appParams simtypes.AppParams, cdc *codec.Codec, ak types.AccountKeeper, bk keeper.Keeper,
) simulation.WeightedOperations

WeightedOperations returns all the operations from the module with their respective weights

Types

type SupplyUnmarshaller added in v1.0.0

type SupplyUnmarshaller interface {
	UnmarshalSupply([]byte) (exported.SupplyI, error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL