Versions in this module Expand all Collapse all v0 v0.0.4 Nov 25, 2021 v0.0.3 Nov 25, 2021 v0.0.2 Nov 25, 2021 v0.0.1 Nov 24, 2021 Changes in this version + const BeginBlockEntryKind + const EndBlockEntryKind + const MsgEntryKind + const QueuedMsgEntryKind + func DeriveRand(r *rand.Rand) *rand.Rand + func GetMemberOfInitialState(r *rand.Rand, weights []int) int + func RandIntBetween(r *rand.Rand, min, max int) int + func RandPositiveInt(r *rand.Rand, max sdk.Int) (sdk.Int, error) + func RandStringOfLength(r *rand.Rand, n int) string + func RandSubsetCoins(r *rand.Rand, coins sdk.Coins) sdk.Coins + func RandTimestamp(r *rand.Rand) time.Time + func RandomAmount(r *rand.Rand, max sdk.Int) sdk.Int + func RandomDecAmount(r *rand.Rand, max sdk.Dec) sdk.Dec + func RandomFees(r *rand.Rand, ctx sdk.Context, spendableCoins sdk.Coins) (sdk.Coins, error) + func RandomRequestBeginBlock(r *rand.Rand, params Params, validators mockValidators, pastTimes []time.Time, ...) abci.RequestBeginBlock + type Account struct + Address sdk.AccAddress + PrivKey crypto.PrivKey + PubKey crypto.PubKey + func FindAccount(accs []Account, address sdk.Address) (Account, bool) + func RandomAcc(r *rand.Rand, accs []Account) (Account, int) + func RandomAccounts(r *rand.Rand, n int) []Account + func (acc Account) Equals(acc2 Account) bool + type AppParams map[string]json.RawMessage + func (sp AppParams) GetOrGenerate(cdc *codec.Codec, key string, ptr interface{}, r *rand.Rand, ps ParamSimulator) + type AppStateFn func(r *rand.Rand, accs []Account, config Config) (appState json.RawMessage, accounts []Account, chainId string, ...) + type Config struct + AllInvariants bool + BlockSize int + ChainID string + Commit bool + ExportParamsHeight int + ExportParamsPath string + ExportStatePath string + ExportStatsPath string + GenesisFile string + InitialBlockHeight int + Lean bool + NumBlocks int + OnOperation bool + ParamsFile string + Seed int64 + type ContentSimulatorFn func(r *rand.Rand, ctx sdk.Context, accs []Account) govtypes.Content + type DummyLogWriter struct + func (lw *DummyLogWriter) AddEntry(_ OperationEntry) + func (lw *DummyLogWriter) PrintLogs() + type EventStats map[string]map[string]map[string]int + func NewEventStats() EventStats + func (es EventStats) ExportJSON(path string) + func (es EventStats) Print(w io.Writer) + func (es EventStats) Tally(route, op, evResult string) + type FutureOperation struct + BlockHeight int + BlockTime time.Time + Op Operation + type LogWriter interface + AddEntry func(OperationEntry) + PrintLogs func() + func NewLogWriter(testingmode bool) LogWriter + type Operation func(r *rand.Rand, app *baseapp.BaseApp, ctx sdk.Context, accounts []Account, ...) (OperationMsg OperationMsg, futureOps []FutureOperation, err error) + type OperationEntry struct + EntryKind string + Height int64 + Operation json.RawMessage + Order int64 + func BeginBlockEntry(height int64) OperationEntry + func EndBlockEntry(height int64) OperationEntry + func MsgEntry(height, order int64, opMsg OperationMsg) OperationEntry + func NewOperationEntry(entry string, height, order int64, op json.RawMessage) OperationEntry + func QueuedMsgEntry(height int64, opMsg OperationMsg) OperationEntry + func (oe OperationEntry) MustMarshal() json.RawMessage + type OperationMsg struct + Comment string + Msg json.RawMessage + Name string + OK bool + Route string + func NewOperationMsg(msg sdk.Msg, ok bool, comment string) OperationMsg + func NewOperationMsgBasic(route, name, comment string, ok bool, msg []byte) OperationMsg + func NoOpMsg(route string) OperationMsg + func (om OperationMsg) LogEvent(eventLogger func(route, op, evResult string)) + func (om OperationMsg) MustMarshal() json.RawMessage + func (om OperationMsg) String() string + type OperationQueue map[int][]Operation + func NewOperationQueue() OperationQueue + type ParamChange struct + Key string + SimValue SimValFn + Subspace string + func NewSimParamChange(subspace, key string, simVal SimValFn) ParamChange + func (spc ParamChange) ComposedKey() string + type ParamSimulator func(r *rand.Rand) + type Params struct + BlockSizeTransitionMatrix TransitionMatrix + EvidenceFraction float64 + InitialLivenessWeightings []int + LivenessTransitionMatrix TransitionMatrix + NumKeys int + PastEvidenceFraction float64 + func RandomParams(r *rand.Rand) Params + func SimulateFromSeed(tb testing.TB, w io.Writer, app *baseapp.BaseApp, appStateFn AppStateFn, ...) (stopEarly bool, exportedParams Params, err error) + type SimValFn func(r *rand.Rand) string + type StandardLogWriter struct + OpEntries []OperationEntry + func (lw *StandardLogWriter) AddEntry(opEntry OperationEntry) + func (lw *StandardLogWriter) PrintLogs() + type TransitionMatrix struct + func CreateTransitionMatrix(weights [][]int) (TransitionMatrix, error) + func (t TransitionMatrix) NextState(r *rand.Rand, i int) int + type WeightedOperation struct + Op Operation + Weight int + func NewWeightedOperation(weight int, op Operation) WeightedOperation + type WeightedOperations []WeightedOperation + type WeightedProposalContent struct + AppParamsKey string + ContentSimulatorFn ContentSimulatorFn + DefaultWeight int