network

package
v0.5.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Network

type Network interface {
	GetContext() sdktypes.Context
	GetChainID() string
	GetBaseDenom() string
	GetOtherDenoms() []string
	GetValidators() []stakingtypes.Validator

	NextBlock() error
	NextBlockAfter(duration time.Duration) error
	NextBlockWithTxs(txBytes ...[]byte) (*abcitypes.ResponseFinalizeBlock, error)

	// Clients
	GetAuthClient() authtypes.QueryClient
	GetAuthzClient() authz.QueryClient
	GetBankClient() banktypes.QueryClient
	GetStakingClient() stakingtypes.QueryClient
	GetDistrClient() distrtypes.QueryClient

	BroadcastTxSync(txBytes []byte) (abcitypes.ExecTxResult, error)
	Simulate(txBytes []byte) (*txtypes.SimulateResponse, error)
	CheckTx(txBytes []byte) (*abcitypes.ResponseCheckTx, error)

	// GetIBCChain returns the IBC test chain.
	// NOTE: this is only used for testing IBC related functionality.
	// The idea is to deprecate this eventually.
	GetIBCChain(t *testing.T, coord *ibctesting.Coordinator) *ibctesting.TestChain
	GetEncodingConfig() sdktestutil.TestEncodingConfig
}

Network is the interface that wraps the common methods to interact with integration test network.

It was designed to avoid users to access module's keepers directly and force integration tests to be closer to the real user's behavior.

Jump to

Keyboard shortcuts

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