simulation

package
v0.3.3-gamma Latest Latest
Warning

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

Go to latest
Published: May 10, 2023 License: Apache-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var GlobalRollappList []types.SimRollapp = []types.SimRollapp{}

GlobalRollappIdList is a list of created rollapps

View Source
var GlobalSequencerAddressesList []types.SimSequencer = []types.SimSequencer{}

GlobalSequencerAddressesList is a list of created sequencers

Functions

func FindAccount

func FindAccount(accs []simtypes.Account, address string) (simtypes.Account, bool)

FindAccount find a specific address from an account list

func GenAndDeliverMsgWithRandFees

func GenAndDeliverMsgWithRandFees(
	msg sdk.Msg,
	msgType string,
	moduleName string,
	r *rand.Rand,
	app *baseapp.BaseApp,
	ctx *sdk.Context,
	simAccount *simtypes.Account,
	bk types.BankKeeper,
	ak types.AccountKeeper,
	futureOperation []simtypes.FutureOperation,
	bExpectedError bool) (simtypes.OperationMsg, []simtypes.FutureOperation, error)

GenAndDeliverMsgWithRandFees generates a transaction with a random fee and expected Error flag (bExpectedError). GenAndDeliverMsgWithRandFees wraps GenAndDeliverTxWithRand Fees and checks whether or not the operation failed as expected by bExpectedError flag

func GenAndDeliverTx

GenAndDeliverTx generates a transactions and delivers it. Copied from github.com/cosmos/cosmos-sdk/x/simulation/util

func GenAndDeliverTxWithRandFees

func GenAndDeliverTxWithRandFees(txCtx simulation.OperationInput) (simtypes.OperationMsg, []simtypes.FutureOperation, error)

GenAndDeliverTxWithRandFees generates a transaction with a random fee and delivers it. Copied from github.com/cosmos/cosmos-sdk/x/simulation/util because of the need to increase the gas as haedcoded passed in helpers.GenTx

func RandomRollapp

func RandomRollapp(r *rand.Rand, rollappList []types.SimRollapp) (types.SimRollapp, int)

RandomRollapp picks and returns a random rollapp from an array and returs its position in the array.

func RandomSequencer

func RandomSequencer(r *rand.Rand, sequencerList []types.SimSequencer) (types.SimSequencer, int)

RandomSequencer picks and returns a random sequencer from an array and returs its position in the array.

Types

This section is empty.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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