simulation

package
v1.20.2 Latest Latest
Warning

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

Go to latest
Published: Nov 21, 2024 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

View Source
const (
	//nolint:gosec // not credentials
	OpWeightMsgAddAttribute = "op_weight_msg_add_attribute"
	//nolint:gosec // not credentials
	OpWeightMsgUpdateAttribute = "op_weight_msg_update_attribute"
	//nolint:gosec // not credentials
	OpWeightMsgDeleteAttribute = "op_weight_msg_delete_attribute"
	//nolint:gosec // not credentials
	OpWeightMsgDeleteDistinctAttribute = "op_weight_msg_delete_distinct_attribute"
	//nolint:gosec // not credentials
	OpWeightMsgSetAccountData = "op_weight_msg_set_account_data"
)

Simulation operation weights constants

View Source
const (
	MaxValueLength = "max_value_length"
)

Simulation parameter constants

Variables

This section is empty.

Functions

func Dispatch added in v1.5.0

Dispatch sends an operation to the chain using a given account/funds on account for fees. Failures on the server side are handled as no-op msg operations with the error string as the status/response.

func GenMaxValueLength

func GenMaxValueLength(r *rand.Rand) uint32

GenMaxValueLength randomized MaxValueLength

func NewDecodeStore added in v1.5.0

func NewDecodeStore(cdc codec.Codec) func(kvA, kvB kv.Pair) string

NewDecodeStore returns a decoder function closure that unmarshalls the KVPair's Value

func ParamChanges

func ParamChanges(_ *rand.Rand) []simtypes.LegacyParamChange

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

func RandomizedGenState

func RandomizedGenState(simState *module.SimulationState)

RandomizedGenState generates a random GenesisState for distribution

func SimulateMsgAddAttribute added in v1.5.0

SimulateMsgAddAttribute will add an attribute under an account with a random type.

func SimulateMsgDeleteAttribute added in v1.5.0

SimulateMsgDeleteAttribute will dispatch a delete attribute operation against a random record

func SimulateMsgDeleteDistinctAttribute added in v1.5.0

func SimulateMsgDeleteDistinctAttribute(simState module.SimulationState, k keeper.Keeper, ak authkeeper.AccountKeeperI, bk bankkeeper.ViewKeeper, nk namekeeper.Keeper) simtypes.Operation

SimulateMsgDeleteDistinctAttribute will dispatch a delete attribute operation against a random record

func SimulateMsgSetAccountData added in v1.16.0

func SimulateMsgSetAccountData(simState module.SimulationState, k keeper.Keeper, ak authkeeper.AccountKeeperI, bk bankkeeper.ViewKeeper) simtypes.Operation

SimulateMsgSetAccountData will dispatch a set account data operation for a random account.

func SimulateMsgUpdateAttribute added in v1.5.0

SimulateMsgUpdateAttribute will add an attribute under an account with a random type.

func WeightedOperations added in v1.5.0

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

Types

This section is empty.

Jump to

Keyboard shortcuts

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