package mocks

import "github.com/centrifuge/go-substrate-rpc-client/v4/rpc/chain/mocks"

Index

Types

type Chain

type Chain struct {
	mock.Mock
}

Chain is an autogenerated mock type for the Chain type

func NewChain

func NewChain(t NewChainT) *Chain

NewChain creates a new instance of Chain. It also registers a testing interface on the mock and a cleanup function to assert the mocks expectations.

func (*Chain) GetBlock

func (_m *Chain) GetBlock(blockHash types.Hash) (*types.SignedBlock, error)

GetBlock provides a mock function with given fields: blockHash

func (*Chain) GetBlockHash

func (_m *Chain) GetBlockHash(blockNumber uint64) (types.Hash, error)

GetBlockHash provides a mock function with given fields: blockNumber

func (*Chain) GetBlockHashLatest

func (_m *Chain) GetBlockHashLatest() (types.Hash, error)

GetBlockHashLatest provides a mock function with given fields:

func (*Chain) GetBlockLatest

func (_m *Chain) GetBlockLatest() (*types.SignedBlock, error)

GetBlockLatest provides a mock function with given fields:

func (*Chain) GetFinalizedHead

func (_m *Chain) GetFinalizedHead() (types.Hash, error)

GetFinalizedHead provides a mock function with given fields:

func (*Chain) GetHeader

func (_m *Chain) GetHeader(blockHash types.Hash) (*types.Header, error)

GetHeader provides a mock function with given fields: blockHash

func (*Chain) GetHeaderLatest

func (_m *Chain) GetHeaderLatest() (*types.Header, error)

GetHeaderLatest provides a mock function with given fields:

func (*Chain) SubscribeFinalizedHeads

func (_m *Chain) SubscribeFinalizedHeads() (*chain.FinalizedHeadsSubscription, error)

SubscribeFinalizedHeads provides a mock function with given fields:

func (*Chain) SubscribeNewHeads

func (_m *Chain) SubscribeNewHeads() (*chain.NewHeadsSubscription, error)

SubscribeNewHeads provides a mock function with given fields:

type NewChainT

type NewChainT interface {
	mock.TestingT
	Cleanup(func())
}

Source Files

chain.go

Version
v4.2.1 (latest)
Published
Dec 5, 2023
Platform
linux/amd64
Imports
3 packages
Last checked
1 week ago

Tools for package owners.