mocks

package
v25.0.3-indexer-4240526b Latest Latest
Warning

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

Go to latest
Published: Jul 24, 2024 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GRPCClientMock added in v25.2.1

type GRPCClientMock struct {
	Error error
}

func (*GRPCClientMock) PushData added in v25.2.1

func (g *GRPCClientMock) PushData(ctx context.Context, height uint64, pools []sqsdomain.PoolI, takerFeesMap sqsdomain.TakerFeeMap) error

PushData implements domain.SQSGRPClient.

type NodeStatusCheckerMock

type NodeStatusCheckerMock struct {
	// IsSyncing is the value to return when IsNodeSyncing is called.
	IsSyncing bool
	// IsNodeSyncingError is the error to return when IsNodeSyncing is called.
	IsNodeSyncingError error
	// IsNodeSyncingCalled is a flag indicating if IsNodeSyncing was called.
	IsNodeSyncingCalled bool
}

NodeStatusCheckerMock is a mock implementation of domain.NodeStatusChecker.

func (*NodeStatusCheckerMock) IsNodeSyncing

func (n *NodeStatusCheckerMock) IsNodeSyncing(ctx types.Context) (bool, error)

IsNodeSyncing implements domain.NodeStatusChecker.

type PoolsExtractorMock added in v25.2.1

type PoolsExtractorMock struct {
	// AllBlockDataError is the error to return when ProcessAllBlockData is called.
	AllBlockDataError error
	// ChangedBlockDataError is the error to return when ProcessChangedBlockData is called.
	ChangedBlockDataError error
	// IsProcessAllBlockDataCalled is a flag indicating if ProcessAllBlockData was called.
	IsProcessAllBlockDataCalled bool
	// IsProcessAllChangedDataCalled is a flag indicating if ProcessChangedBlockData was called.
	IsProcessAllChangedDataCalled bool
	// If this is non-empty, ProcessAllBlockData(...) will panic with this message.
	ProcessAllBlockDataPanicMsg string
	// Block pools to return
	BlockPools commondomain.BlockPools
}

func (*PoolsExtractorMock) ExtractAll added in v25.2.1

ExtractAll implements commondomain.PoolExtractor.

func (*PoolsExtractorMock) ExtractChanged added in v25.2.1

func (p *PoolsExtractorMock) ExtractChanged(ctx types.Context) (commondomain.BlockPools, error)

ExtractChanged implements commondomain.PoolExtractor.

type PoolsTransformerMock added in v25.2.1

type PoolsTransformerMock struct {
	PoolReturn     []sqsdomain.PoolI
	TakerFeeReturn sqsdomain.TakerFeeMap
	ErrReturn      error
}

func (*PoolsTransformerMock) Transform added in v25.2.1

Transform implements domain.PoolsTransformer.

Jump to

Keyboard shortcuts

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