Documentation ¶
Index ¶
- func GenTx(gen client.TxConfig, msgs []sdk.Msg, feeAmt sdk.Coins, gas uint64, ...) (sdk.Tx, error)
- func New(t *testing.T) *stargazeapp.App
- func SetupWithGenesisAccounts(t *testing.T, dir string, genAccs []authtypes.GenesisAccount, ...) *stargazeapp.App
- func SetupWithGenesisValSet(t *testing.T, dir string, valSet *tmtypes.ValidatorSet, ...) *stargazeapp.App
- func SignCheckDeliver(t *testing.T, txCfg client.TxConfig, app *bam.BaseApp, _ tmproto.Header, ...) (sdk.GasInfo, *sdk.Result, error)
- type PV
- type SetupOptions
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func New ¶
func New(t *testing.T) *stargazeapp.App
New creates application instance with in-memory database and disabled logging.
func SetupWithGenesisAccounts ¶
func SetupWithGenesisAccounts(t *testing.T, dir string, genAccs []authtypes.GenesisAccount, balances ...banktypes.Balance) *stargazeapp.App
SetupWithGenesisAccounts initializes a new SimApp with the provided genesis accounts and possible balances.
func SetupWithGenesisValSet ¶
func SetupWithGenesisValSet(t *testing.T, dir string, valSet *tmtypes.ValidatorSet, genAccs []authtypes.GenesisAccount, balances ...banktypes.Balance) *stargazeapp.App
SetupWithGenesisValSet initializes a new SimApp 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 simapp from first genesis account. A Nop logger is set in SimApp.
func SignCheckDeliver ¶
func SignCheckDeliver( t *testing.T, txCfg client.TxConfig, app *bam.BaseApp, _ tmproto.Header, msgs []sdk.Msg, chainID string, accNums, accSeqs []uint64, simulate bool, expSimPass, expPass bool, priv ...cryptotypes.PrivKey, ) (sdk.GasInfo, *sdk.Result, error)
SignCheckDeliver checks a generated signed transaction and simulates a block commitment with the given transaction. A test assertion is made using the parameter 'expPass' against the result. A corresponding result is returned.
Types ¶
type PV ¶
type PV struct {
PrivKey cryptotypes.PrivKey
}
MockPV implements PrivValidator without any safety or persistence. Only use it for testing.
func (PV) SignProposal ¶
SignProposal implements PrivValidator interface
type SetupOptions ¶
type SetupOptions struct { Logger log.Logger DB *dbm.MemDB AppOpts servertypes.AppOptions WasmOpts []wasmkeeper.Option }
SetupOptions defines arguments that are passed into `WasmApp` constructor.