mocks

package
v0.0.0-...-2c4dd60 Latest Latest
Warning

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

Go to latest
Published: Jun 20, 2022 License: MIT Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type BlobPeerConn

type BlobPeerConn struct {
	mock.Mock
}

BlobPeerConn is an autogenerated mock type for the BlobPeerConn type

func NewBlobPeerConn

func NewBlobPeerConn(t mockConstructorTestingTNewBlobPeerConn) *BlobPeerConn

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

func (*BlobPeerConn) AddStateURI

func (_m *BlobPeerConn) AddStateURI(stateURI string)

AddStateURI provides a mock function with given fields: stateURI

func (*BlobPeerConn) Addresses

func (_m *BlobPeerConn) Addresses() types.Set[types.Address]

Addresses provides a mock function with given fields:

func (*BlobPeerConn) Close

func (_m *BlobPeerConn) Close() error

Close provides a mock function with given fields:

func (*BlobPeerConn) DeviceUniqueID

func (_m *BlobPeerConn) DeviceUniqueID() string

DeviceUniqueID provides a mock function with given fields:

func (*BlobPeerConn) DialInfo

func (_m *BlobPeerConn) DialInfo() swarm.PeerDialInfo

DialInfo provides a mock function with given fields:

func (*BlobPeerConn) Dialable

func (_m *BlobPeerConn) Dialable() bool

Dialable provides a mock function with given fields:

func (*BlobPeerConn) Endpoint

func (_m *BlobPeerConn) Endpoint(dialInfo swarm.PeerDialInfo) (swarm.PeerEndpoint, bool)

Endpoint provides a mock function with given fields: dialInfo

func (*BlobPeerConn) Endpoints

func (_m *BlobPeerConn) Endpoints() map[swarm.PeerDialInfo]swarm.PeerEndpoint

Endpoints provides a mock function with given fields:

func (*BlobPeerConn) EnsureConnected

func (_m *BlobPeerConn) EnsureConnected(ctx context.Context) error

EnsureConnected provides a mock function with given fields: ctx

func (*BlobPeerConn) Failures

func (_m *BlobPeerConn) Failures() uint64

Failures provides a mock function with given fields:

func (*BlobPeerConn) FetchBlobChunk

func (_m *BlobPeerConn) FetchBlobChunk(sha3 types.Hash) ([]byte, error)

FetchBlobChunk provides a mock function with given fields: sha3

func (*BlobPeerConn) FetchBlobManifest

func (_m *BlobPeerConn) FetchBlobManifest(blobID pb.ID) (pb.Manifest, error)

FetchBlobManifest provides a mock function with given fields: blobID

func (*BlobPeerConn) LastContact

func (_m *BlobPeerConn) LastContact() time.Time

LastContact provides a mock function with given fields:

func (*BlobPeerConn) LastFailure

func (_m *BlobPeerConn) LastFailure() time.Time

LastFailure provides a mock function with given fields:

func (*BlobPeerConn) PublicKeys

PublicKeys provides a mock function with given fields: addr

func (*BlobPeerConn) Ready

func (_m *BlobPeerConn) Ready() bool

Ready provides a mock function with given fields:

func (*BlobPeerConn) RemainingBackoff

func (_m *BlobPeerConn) RemainingBackoff() time.Duration

RemainingBackoff provides a mock function with given fields:

func (*BlobPeerConn) RemoveStateURI

func (_m *BlobPeerConn) RemoveStateURI(stateURI string)

RemoveStateURI provides a mock function with given fields: stateURI

func (*BlobPeerConn) SendBlobChunk

func (_m *BlobPeerConn) SendBlobChunk(chunk []byte, exists bool) error

SendBlobChunk provides a mock function with given fields: chunk, exists

func (*BlobPeerConn) SendBlobManifest

func (_m *BlobPeerConn) SendBlobManifest(m pb.Manifest, exists bool) error

SendBlobManifest provides a mock function with given fields: m, exists

func (*BlobPeerConn) SetDeviceUniqueID

func (_m *BlobPeerConn) SetDeviceUniqueID(id string)

SetDeviceUniqueID provides a mock function with given fields: id

func (*BlobPeerConn) StateURIs

func (_m *BlobPeerConn) StateURIs() types.Set[string]

StateURIs provides a mock function with given fields:

func (*BlobPeerConn) Transport

func (_m *BlobPeerConn) Transport() swarm.Transport

Transport provides a mock function with given fields:

func (*BlobPeerConn) UpdateConnStats

func (_m *BlobPeerConn) UpdateConnStats(success bool)

UpdateConnStats provides a mock function with given fields: success

type BlobProtocol

type BlobProtocol struct {
	mock.Mock
}

BlobProtocol is an autogenerated mock type for the BlobProtocol type

func NewBlobProtocol

func NewBlobProtocol(t mockConstructorTestingTNewBlobProtocol) *BlobProtocol

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

func (*BlobProtocol) Autoclose

func (_m *BlobProtocol) Autoclose()

Autoclose provides a mock function with given fields:

func (*BlobProtocol) AutocloseWithCleanup

func (_m *BlobProtocol) AutocloseWithCleanup(closeFn func())

AutocloseWithCleanup provides a mock function with given fields: closeFn

func (*BlobProtocol) Close

func (_m *BlobProtocol) Close() error

Close provides a mock function with given fields:

func (*BlobProtocol) Ctx

func (_m *BlobProtocol) Ctx() context.Context

Ctx provides a mock function with given fields:

func (*BlobProtocol) Done

func (_m *BlobProtocol) Done() <-chan struct{}

Done provides a mock function with given fields:

func (*BlobProtocol) Go

func (_m *BlobProtocol) Go(ctx context.Context, name string, fn func(context.Context)) <-chan struct{}

Go provides a mock function with given fields: ctx, name, fn

func (*BlobProtocol) Name

func (_m *BlobProtocol) Name() string

Name provides a mock function with given fields:

func (*BlobProtocol) NewChild

func (_m *BlobProtocol) NewChild(ctx context.Context, name string) *process.Process

NewChild provides a mock function with given fields: ctx, name

func (*BlobProtocol) ProcessTree

func (_m *BlobProtocol) ProcessTree() map[string]interface{}

ProcessTree provides a mock function with given fields:

func (*BlobProtocol) ProvidersOfBlob

func (_m *BlobProtocol) ProvidersOfBlob(ctx context.Context, blobID pb.ID) <-chan protoblob.BlobPeerConn

ProvidersOfBlob provides a mock function with given fields: ctx, blobID

func (*BlobProtocol) SpawnChild

func (_m *BlobProtocol) SpawnChild(ctx context.Context, child process.Spawnable) error

SpawnChild provides a mock function with given fields: ctx, child

func (*BlobProtocol) Start

func (_m *BlobProtocol) Start() error

Start provides a mock function with given fields:

func (*BlobProtocol) State

func (_m *BlobProtocol) State() process.State

State provides a mock function with given fields:

type BlobTransport

type BlobTransport struct {
	mock.Mock
}

BlobTransport is an autogenerated mock type for the BlobTransport type

func NewBlobTransport

func NewBlobTransport(t mockConstructorTestingTNewBlobTransport) *BlobTransport

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

func (*BlobTransport) AnnounceBlobs

func (_m *BlobTransport) AnnounceBlobs(ctx context.Context, blobIDs types.Set[pb.ID])

AnnounceBlobs provides a mock function with given fields: ctx, blobIDs

func (*BlobTransport) Autoclose

func (_m *BlobTransport) Autoclose()

Autoclose provides a mock function with given fields:

func (*BlobTransport) AutocloseWithCleanup

func (_m *BlobTransport) AutocloseWithCleanup(closeFn func())

AutocloseWithCleanup provides a mock function with given fields: closeFn

func (*BlobTransport) Close

func (_m *BlobTransport) Close() error

Close provides a mock function with given fields:

func (*BlobTransport) Ctx

func (_m *BlobTransport) Ctx() context.Context

Ctx provides a mock function with given fields:

func (*BlobTransport) Done

func (_m *BlobTransport) Done() <-chan struct{}

Done provides a mock function with given fields:

func (*BlobTransport) Go

func (_m *BlobTransport) Go(ctx context.Context, name string, fn func(context.Context)) <-chan struct{}

Go provides a mock function with given fields: ctx, name, fn

func (*BlobTransport) Name

func (_m *BlobTransport) Name() string

Name provides a mock function with given fields:

func (*BlobTransport) NewChild

func (_m *BlobTransport) NewChild(ctx context.Context, name string) *process.Process

NewChild provides a mock function with given fields: ctx, name

func (*BlobTransport) NewPeerConn

func (_m *BlobTransport) NewPeerConn(ctx context.Context, dialAddr string) (swarm.PeerConn, error)

NewPeerConn provides a mock function with given fields: ctx, dialAddr

func (*BlobTransport) OnBlobChunkRequest

func (_m *BlobTransport) OnBlobChunkRequest(handler func(types.Hash, protoblob.BlobPeerConn))

OnBlobChunkRequest provides a mock function with given fields: handler

func (*BlobTransport) OnBlobManifestRequest

func (_m *BlobTransport) OnBlobManifestRequest(handler func(pb.ID, protoblob.BlobPeerConn))

OnBlobManifestRequest provides a mock function with given fields: handler

func (*BlobTransport) ProcessTree

func (_m *BlobTransport) ProcessTree() map[string]interface{}

ProcessTree provides a mock function with given fields:

func (*BlobTransport) ProvidersOfBlob

func (_m *BlobTransport) ProvidersOfBlob(ctx context.Context, blobID pb.ID) (<-chan protoblob.BlobPeerConn, error)

ProvidersOfBlob provides a mock function with given fields: ctx, blobID

func (*BlobTransport) SpawnChild

func (_m *BlobTransport) SpawnChild(ctx context.Context, child process.Spawnable) error

SpawnChild provides a mock function with given fields: ctx, child

func (*BlobTransport) Start

func (_m *BlobTransport) Start() error

Start provides a mock function with given fields:

func (*BlobTransport) State

func (_m *BlobTransport) State() process.State

State provides a mock function with given fields:

Jump to

Keyboard shortcuts

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