core

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2023 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenRandomAddr

func GenRandomAddr() sdk.AccAddress

func GenRandomHexString

func GenRandomHexString(len int) string

func GenRandomKeyManager

func GenRandomKeyManager() keys.KeyManager

func ParseMnemonicFromFile

func ParseMnemonicFromFile(fileName string) string

func ParseRelayerMnemonic added in v0.0.7

func ParseRelayerMnemonic(i int) string

ParseRelayerMnemonic read the relayer mnemonic from file

func ParseValidatorMnemonic

func ParseValidatorMnemonic(i int) string

ParseValidatorMnemonic read the validator mnemonic from file

func RandInt64 added in v0.0.7

func RandInt64(min, max int64) int64

RandInt64 generate random int64 between min and max

func YamlString added in v0.0.7

func YamlString(data interface{}) string

Types

type BaseSuite

type BaseSuite struct {
	suite.Suite
	Config           *Config
	Client           *client.GreenfieldClient
	TmClient         *client.TendermintClient
	Validator        keys.KeyManager
	Relayer          keys.KeyManager
	StorageProviders []SPKeyManagers
}

func (*BaseSuite) GenAndChargeAccounts

func (s *BaseSuite) GenAndChargeAccounts(n int, balance int64) (accounts []keys.KeyManager)

func (*BaseSuite) SendTxBlock

func (s *BaseSuite) SendTxBlock(msg sdk.Msg, from keys.KeyManager) (txRes *sdk.TxResponse)

func (*BaseSuite) SetupSuite

func (s *BaseSuite) SetupSuite()

type Config

type Config struct {
	GrpcAddr          string        `yaml:"GrpcAddr"`
	TendermintAddr    string        `yaml:"TendermintAddr"`
	ChainId           string        `yaml:"ChainId"`
	ValidatorMnemonic string        `yaml:"Mnemonic"`        // validator operator account mnemonic with enough balance
	RelayerMnemonic   string        `yaml:"RelayerMnemonic"` // relayer's mnemonic for bls key
	SPMnemonics       []SPMnemonics `yaml:"SPMnemonics"`
	Denom             string        `yaml:"Denom"`
}

func InitConfig

func InitConfig() *Config

func InitE2eConfig

func InitE2eConfig() *Config

type SPKeyManagers

type SPKeyManagers struct {
	OperatorKey keys.KeyManager
	SealKey     keys.KeyManager
	FundingKey  keys.KeyManager
	ApprovalKey keys.KeyManager
}

type SPMnemonics

type SPMnemonics struct {
	OperatorMnemonic string `yaml:"OperatorMnemonic"` // operator account mnemonic with enough balance
	SealMnemonic     string `yaml:"SealMnemonic"`     // seal account mnemonic with enough balance
	FundingMnemonic  string `yaml:"FundingMnemonic"`  // funding account mnemonic with enough balance
	ApprovalMnemonic string `yaml:"ApprovalMnemonic"` // approval account mnemonic with enough balance
}

func ParseSPMnemonics

func ParseSPMnemonics(i int) SPMnemonics

ParseSPMnemonics read the sp mnemonics from file

Jump to

Keyboard shortcuts

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