tester

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 10, 2024 License: MIT Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type SelectionMode

type SelectionMode uint8
var (
	SelectByIndex    SelectionMode = 0
	SelectRandom     SelectionMode = 1
	SelectRoundRobin SelectionMode = 2
)

type Tester

type Tester struct {
	// contains filtered or unexported fields
}

func NewTester

func NewTester(config *TesterConfig) *Tester

func (*Tester) CheckChildWalletBalance

func (tester *Tester) CheckChildWalletBalance(childWallet *txbuilder.Wallet) (*types.Transaction, error)

func (*Tester) GetClient

func (tester *Tester) GetClient(mode SelectionMode, input int) *txbuilder.Client

func (*Tester) GetRootWallet

func (tester *Tester) GetRootWallet() *txbuilder.Wallet

func (*Tester) GetTxPool

func (tester *Tester) GetTxPool() *txbuilder.TxPool

func (*Tester) GetWallet

func (tester *Tester) GetWallet(mode SelectionMode, input int) *txbuilder.Wallet

func (*Tester) PrepareClients

func (tester *Tester) PrepareClients() error

func (*Tester) PrepareWallets

func (tester *Tester) PrepareWallets(seed string) error

func (*Tester) SetScenario

func (tester *Tester) SetScenario(name string)

func (*Tester) Start

func (tester *Tester) Start(seed string) error

func (*Tester) Stop

func (tester *Tester) Stop()

type TesterConfig

type TesterConfig struct {
	RpcHosts       []string     // rpc host urls to use for blob tests
	WalletPrivkey  string       // pre-funded wallet privkey to use for blob tests
	WalletCount    uint64       // number of child wallets to generate & use (based on walletPrivkey)
	WalletPrefund  *uint256.Int // amount of funds to send to each child wallet
	WalletMinfund  *uint256.Int // min amount of funds child wallets should hold - refill with walletPrefund if lower
	RefillInterval uint64
}

Jump to

Keyboard shortcuts

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