Documentation
¶
Index ¶
- Variables
- func AddGenesisAccount(addr sdk.AccAddress, appState app.GenesisState, cdc codec.Codec) (map[string]json.RawMessage, error)
- func GenerateKeyringSigner(t *testing.T, acct string) *types.KeyringSigner
- func GenesisStateWithSingleValidator(t *testing.T, testApp *app.App) (app.GenesisState, *tmtypes.ValidatorSet)
- func NewDefaultGenesisState(cdc codec.JSONCodec) app.GenesisState
- func SetupTestAppWithGenesisValSet(t *testing.T) *app.App
Constants ¶
This section is empty.
Variables ¶
var DefaultConsensusParams = &tmproto.ConsensusParams{ Block: &tmproto.BlockParams{ MaxBytes: 200000, MaxGas: 2000000, }, Evidence: &tmproto.EvidenceParams{ MaxAgeNumBlocks: 302400, MaxAgeDuration: 504 * time.Hour, MaxBytes: 10000, }, Validator: &tmproto.ValidatorParams{ PubKeyTypes: []string{ tmtypes.ABCIPubKeyTypeEd25519, }, }, }
DefaultConsensusParams defines the default Tendermint consensus params used in SimApp testing.
Functions ¶
func AddGenesisAccount ¶
func AddGenesisAccount(addr sdk.AccAddress, appState app.GenesisState, cdc codec.Codec) (map[string]json.RawMessage, error)
AddGenesisAccount mimics the cli addGenesisAccount command, providing an account with an allocation of to "token" and "celes" tokens in the genesis state
func GenerateKeyringSigner ¶
func GenerateKeyringSigner(t *testing.T, acct string) *types.KeyringSigner
GenerateKeyringSigner creates a types.KeyringSigner with keys generated for the provided accounts
func GenesisStateWithSingleValidator ¶ added in v0.5.0
func GenesisStateWithSingleValidator(t *testing.T, testApp *app.App) (app.GenesisState, *tmtypes.ValidatorSet)
SetupWithGenesisValSet initializes GenesisState with a single validator and genesis accounts that also act as delegators.
func NewDefaultGenesisState ¶
func NewDefaultGenesisState(cdc codec.JSONCodec) app.GenesisState
NewDefaultGenesisState generates the default state for the application.
func SetupTestAppWithGenesisValSet ¶ added in v0.5.0
SetupTestAppWithGenesisValSet initializes a new app with a validator set and genesis accounts that also act as delegators. For simplicity, each validator is bonded with a delegation of one consensus engine unit in the default token of the app from first genesis account. A Nop logger is set in app.
Types ¶
This section is empty.