testutil

package
v0.4.2 Latest Latest
Warning

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

Go to latest
Published: Mar 6, 2024 License: GPL-3.0 Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConstructBlock

func ConstructBlock(blockHashStr string, height uint64) *types.Block

func ConstructBlocks

func ConstructBlocks(height uint64, num int) []*types.Block

func GetChainMetaFunc

func GetChainMetaFunc() *types.ChainMeta

func MockConsensusConfig

func MockConsensusConfig(logger logrus.FieldLogger, ctrl *gomock.Controller, t *testing.T) *common.Config

func MockMiniBlockSync

func MockMiniBlockSync(ctrl *gomock.Controller) *mock_block_sync.MockSync

func MockMiniNetwork

func MockMiniNetwork(ctrl *gomock.Controller, selfAddr string) *mock_network.MockNetwork

func ResetMockBlockLedger

func ResetMockBlockLedger()

func ResetMockChainMeta

func ResetMockChainMeta()

func SetMockBlockLedger

func SetMockBlockLedger(block *types.Block, local bool)

func SetMockChainMeta

func SetMockChainMeta(chainMeta *types.ChainMeta)

Types

This section is empty.

Jump to

Keyboard shortcuts

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