mocks

package
v1.13.0-rc.1 Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Core added in v1.12.0

type Core struct {
	mock.Mock
}

Core is an autogenerated mock type for the Core type

func NewCore added in v1.12.0

func NewCore(t mockConstructorTestingTNewCore) *Core

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

func (*Core) Check added in v1.12.0

func (_m *Core) Check(_a0 zapcore.Entry, _a1 *zapcore.CheckedEntry) *zapcore.CheckedEntry

Check provides a mock function with given fields: _a0, _a1

func (*Core) Enabled added in v1.12.0

func (_m *Core) Enabled(_a0 zapcore.Level) bool

Enabled provides a mock function with given fields: _a0

func (*Core) Sync added in v1.12.0

func (_m *Core) Sync() error

Sync provides a mock function with given fields:

func (*Core) With added in v1.12.0

func (_m *Core) With(_a0 []zapcore.Field) zapcore.Core

With provides a mock function with given fields: _a0

func (*Core) Write added in v1.12.0

func (_m *Core) Write(_a0 zapcore.Entry, _a1 []zapcore.Field) error

Write provides a mock function with given fields: _a0, _a1

type DirectRepository

type DirectRepository struct {
	mock.Mock
}

DirectRepository is an autogenerated mock type for the DirectRepository type

func NewDirectRepository

func NewDirectRepository(t mockConstructorTestingTNewDirectRepository) *DirectRepository

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

func (*DirectRepository) AlsoLogToContentLog

func (_m *DirectRepository) AlsoLogToContentLog(ctx context.Context) context.Context

AlsoLogToContentLog provides a mock function with given fields: ctx

func (*DirectRepository) BlobReader

func (_m *DirectRepository) BlobReader() blob.Reader

BlobReader provides a mock function with given fields:

func (*DirectRepository) BlobVolume

func (_m *DirectRepository) BlobVolume() blob.Volume

BlobVolume provides a mock function with given fields:

func (*DirectRepository) ClientOptions

func (_m *DirectRepository) ClientOptions() repo.ClientOptions

ClientOptions provides a mock function with given fields:

func (*DirectRepository) Close

func (_m *DirectRepository) Close(ctx context.Context) error

Close provides a mock function with given fields: ctx

func (*DirectRepository) ConfigFilename

func (_m *DirectRepository) ConfigFilename() string

ConfigFilename provides a mock function with given fields:

func (*DirectRepository) ContentInfo

func (_m *DirectRepository) ContentInfo(ctx context.Context, contentID index.ID) (index.Info, error)

ContentInfo provides a mock function with given fields: ctx, contentID

func (*DirectRepository) ContentReader

func (_m *DirectRepository) ContentReader() content.Reader

ContentReader provides a mock function with given fields:

func (*DirectRepository) DeriveKey

func (_m *DirectRepository) DeriveKey(purpose []byte, keyLength int) []byte

DeriveKey provides a mock function with given fields: purpose, keyLength

func (*DirectRepository) DisableIndexRefresh

func (_m *DirectRepository) DisableIndexRefresh()

DisableIndexRefresh provides a mock function with given fields:

func (*DirectRepository) FindManifests

func (_m *DirectRepository) FindManifests(ctx context.Context, labels map[string]string) ([]*manifest.EntryMetadata, error)

FindManifests provides a mock function with given fields: ctx, labels

func (*DirectRepository) FormatManager added in v1.12.0

func (_m *DirectRepository) FormatManager() *format.Manager

FormatManager provides a mock function with given fields:

func (*DirectRepository) GetManifest

func (_m *DirectRepository) GetManifest(ctx context.Context, id manifest.ID, data interface{}) (*manifest.EntryMetadata, error)

GetManifest provides a mock function with given fields: ctx, id, data

func (*DirectRepository) IndexBlobs

func (_m *DirectRepository) IndexBlobs(ctx context.Context, includeInactive bool) ([]indexblob.Metadata, error)

IndexBlobs provides a mock function with given fields: ctx, includeInactive

func (*DirectRepository) NewDirectWriter

NewDirectWriter provides a mock function with given fields: ctx, opt

func (*DirectRepository) NewWriter

NewWriter provides a mock function with given fields: ctx, opt

func (*DirectRepository) ObjectFormat

func (_m *DirectRepository) ObjectFormat() format.ObjectFormat

ObjectFormat provides a mock function with given fields:

func (*DirectRepository) OpenObject

func (_m *DirectRepository) OpenObject(ctx context.Context, id object.ID) (object.Reader, error)

OpenObject provides a mock function with given fields: ctx, id

func (*DirectRepository) PrefetchContents

func (_m *DirectRepository) PrefetchContents(ctx context.Context, contentIDs []index.ID, hint string) []index.ID

PrefetchContents provides a mock function with given fields: ctx, contentIDs, hint

func (*DirectRepository) PrefetchObjects

func (_m *DirectRepository) PrefetchObjects(ctx context.Context, objectIDs []object.ID, hint string) ([]index.ID, error)

PrefetchObjects provides a mock function with given fields: ctx, objectIDs, hint

func (*DirectRepository) Refresh

func (_m *DirectRepository) Refresh(ctx context.Context) error

Refresh provides a mock function with given fields: ctx

func (*DirectRepository) Throttler

Throttler provides a mock function with given fields:

func (*DirectRepository) Time

func (_m *DirectRepository) Time() time.Time

Time provides a mock function with given fields:

func (*DirectRepository) Token

func (_m *DirectRepository) Token(password string) (string, error)

Token provides a mock function with given fields: password

func (*DirectRepository) UniqueID

func (_m *DirectRepository) UniqueID() []byte

UniqueID provides a mock function with given fields:

func (*DirectRepository) UpdateDescription

func (_m *DirectRepository) UpdateDescription(d string)

UpdateDescription provides a mock function with given fields: d

func (*DirectRepository) VerifyObject

func (_m *DirectRepository) VerifyObject(ctx context.Context, id object.ID) ([]index.ID, error)

VerifyObject provides a mock function with given fields: ctx, id

type DirectRepositoryWriter

type DirectRepositoryWriter struct {
	mock.Mock
}

DirectRepositoryWriter is an autogenerated mock type for the DirectRepositoryWriter type

func NewDirectRepositoryWriter

func NewDirectRepositoryWriter(t mockConstructorTestingTNewDirectRepositoryWriter) *DirectRepositoryWriter

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

func (*DirectRepositoryWriter) AlsoLogToContentLog

func (_m *DirectRepositoryWriter) AlsoLogToContentLog(ctx context.Context) context.Context

AlsoLogToContentLog provides a mock function with given fields: ctx

func (*DirectRepositoryWriter) BlobReader

func (_m *DirectRepositoryWriter) BlobReader() blob.Reader

BlobReader provides a mock function with given fields:

func (*DirectRepositoryWriter) BlobStorage

func (_m *DirectRepositoryWriter) BlobStorage() blob.Storage

BlobStorage provides a mock function with given fields:

func (*DirectRepositoryWriter) BlobVolume

func (_m *DirectRepositoryWriter) BlobVolume() blob.Volume

BlobVolume provides a mock function with given fields:

func (*DirectRepositoryWriter) ClientOptions

func (_m *DirectRepositoryWriter) ClientOptions() repo.ClientOptions

ClientOptions provides a mock function with given fields:

func (*DirectRepositoryWriter) Close

Close provides a mock function with given fields: ctx

func (*DirectRepositoryWriter) ConcatenateObjects added in v1.12.0

func (_m *DirectRepositoryWriter) ConcatenateObjects(ctx context.Context, objectIDs []object.ID) (object.ID, error)

ConcatenateObjects provides a mock function with given fields: ctx, objectIDs

func (*DirectRepositoryWriter) ConfigFilename

func (_m *DirectRepositoryWriter) ConfigFilename() string

ConfigFilename provides a mock function with given fields:

func (*DirectRepositoryWriter) ContentInfo

func (_m *DirectRepositoryWriter) ContentInfo(ctx context.Context, contentID index.ID) (index.Info, error)

ContentInfo provides a mock function with given fields: ctx, contentID

func (*DirectRepositoryWriter) ContentManager

func (_m *DirectRepositoryWriter) ContentManager() *content.WriteManager

ContentManager provides a mock function with given fields:

func (*DirectRepositoryWriter) ContentReader

func (_m *DirectRepositoryWriter) ContentReader() content.Reader

ContentReader provides a mock function with given fields:

func (*DirectRepositoryWriter) DeleteManifest

func (_m *DirectRepositoryWriter) DeleteManifest(ctx context.Context, id manifest.ID) error

DeleteManifest provides a mock function with given fields: ctx, id

func (*DirectRepositoryWriter) DeriveKey

func (_m *DirectRepositoryWriter) DeriveKey(purpose []byte, keyLength int) []byte

DeriveKey provides a mock function with given fields: purpose, keyLength

func (*DirectRepositoryWriter) DisableIndexRefresh

func (_m *DirectRepositoryWriter) DisableIndexRefresh()

DisableIndexRefresh provides a mock function with given fields:

func (*DirectRepositoryWriter) FindManifests

func (_m *DirectRepositoryWriter) FindManifests(ctx context.Context, labels map[string]string) ([]*manifest.EntryMetadata, error)

FindManifests provides a mock function with given fields: ctx, labels

func (*DirectRepositoryWriter) Flush

Flush provides a mock function with given fields: ctx

func (*DirectRepositoryWriter) FormatManager added in v1.12.0

func (_m *DirectRepositoryWriter) FormatManager() *format.Manager

FormatManager provides a mock function with given fields:

func (*DirectRepositoryWriter) GetManifest

func (_m *DirectRepositoryWriter) GetManifest(ctx context.Context, id manifest.ID, data interface{}) (*manifest.EntryMetadata, error)

GetManifest provides a mock function with given fields: ctx, id, data

func (*DirectRepositoryWriter) IndexBlobs

func (_m *DirectRepositoryWriter) IndexBlobs(ctx context.Context, includeInactive bool) ([]indexblob.Metadata, error)

IndexBlobs provides a mock function with given fields: ctx, includeInactive

func (*DirectRepositoryWriter) NewDirectWriter

NewDirectWriter provides a mock function with given fields: ctx, opt

func (*DirectRepositoryWriter) NewObjectWriter

func (_m *DirectRepositoryWriter) NewObjectWriter(ctx context.Context, opt object.WriterOptions) object.Writer

NewObjectWriter provides a mock function with given fields: ctx, opt

func (*DirectRepositoryWriter) NewWriter

NewWriter provides a mock function with given fields: ctx, opt

func (*DirectRepositoryWriter) ObjectFormat

func (_m *DirectRepositoryWriter) ObjectFormat() format.ObjectFormat

ObjectFormat provides a mock function with given fields:

func (*DirectRepositoryWriter) OnSuccessfulFlush added in v1.12.0

func (_m *DirectRepositoryWriter) OnSuccessfulFlush(callback repo.RepositoryWriterCallback)

OnSuccessfulFlush provides a mock function with given fields: callback

func (*DirectRepositoryWriter) OpenObject

func (_m *DirectRepositoryWriter) OpenObject(ctx context.Context, id object.ID) (object.Reader, error)

OpenObject provides a mock function with given fields: ctx, id

func (*DirectRepositoryWriter) PrefetchContents

func (_m *DirectRepositoryWriter) PrefetchContents(ctx context.Context, contentIDs []index.ID, hint string) []index.ID

PrefetchContents provides a mock function with given fields: ctx, contentIDs, hint

func (*DirectRepositoryWriter) PrefetchObjects

func (_m *DirectRepositoryWriter) PrefetchObjects(ctx context.Context, objectIDs []object.ID, hint string) ([]index.ID, error)

PrefetchObjects provides a mock function with given fields: ctx, objectIDs, hint

func (*DirectRepositoryWriter) PutManifest

func (_m *DirectRepositoryWriter) PutManifest(ctx context.Context, labels map[string]string, payload interface{}) (manifest.ID, error)

PutManifest provides a mock function with given fields: ctx, labels, payload

func (*DirectRepositoryWriter) Refresh

func (_m *DirectRepositoryWriter) Refresh(ctx context.Context) error

Refresh provides a mock function with given fields: ctx

func (*DirectRepositoryWriter) ReplaceManifests added in v1.12.0

func (_m *DirectRepositoryWriter) ReplaceManifests(ctx context.Context, labels map[string]string, payload interface{}) (manifest.ID, error)

ReplaceManifests provides a mock function with given fields: ctx, labels, payload

func (*DirectRepositoryWriter) Throttler

Throttler provides a mock function with given fields:

func (*DirectRepositoryWriter) Time

func (_m *DirectRepositoryWriter) Time() time.Time

Time provides a mock function with given fields:

func (*DirectRepositoryWriter) Token

func (_m *DirectRepositoryWriter) Token(password string) (string, error)

Token provides a mock function with given fields: password

func (*DirectRepositoryWriter) UniqueID

func (_m *DirectRepositoryWriter) UniqueID() []byte

UniqueID provides a mock function with given fields:

func (*DirectRepositoryWriter) UpdateDescription

func (_m *DirectRepositoryWriter) UpdateDescription(d string)

UpdateDescription provides a mock function with given fields: d

func (*DirectRepositoryWriter) VerifyObject

func (_m *DirectRepositoryWriter) VerifyObject(ctx context.Context, id object.ID) ([]index.ID, error)

VerifyObject provides a mock function with given fields: ctx, id

type Reader added in v1.12.0

type Reader struct {
	mock.Mock
}

Reader is an autogenerated mock type for the Reader type

func NewReader added in v1.12.0

func NewReader(t mockConstructorTestingTNewReader) *Reader

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

func (*Reader) Close added in v1.12.0

func (_m *Reader) Close() error

Close provides a mock function with given fields:

func (*Reader) Length added in v1.12.0

func (_m *Reader) Length() int64

Length provides a mock function with given fields:

func (*Reader) Read added in v1.12.0

func (_m *Reader) Read(p []byte) (int, error)

Read provides a mock function with given fields: p

func (*Reader) Seek added in v1.12.0

func (_m *Reader) Seek(offset int64, whence int) (int64, error)

Seek provides a mock function with given fields: offset, whence

type Storage

type Storage struct {
	mock.Mock
}

Storage is an autogenerated mock type for the Storage type

func NewStorage

func NewStorage(t mockConstructorTestingTNewStorage) *Storage

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

func (*Storage) Close

func (_m *Storage) Close(ctx context.Context) error

Close provides a mock function with given fields: ctx

func (*Storage) ConnectionInfo

func (_m *Storage) ConnectionInfo() blob.ConnectionInfo

ConnectionInfo provides a mock function with given fields:

func (*Storage) DeleteBlob

func (_m *Storage) DeleteBlob(ctx context.Context, blobID blob.ID) error

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

func (*Storage) DisplayName

func (_m *Storage) DisplayName() string

DisplayName provides a mock function with given fields:

func (*Storage) ExtendBlobRetention added in v1.13.0

func (_m *Storage) ExtendBlobRetention(ctx context.Context, blobID blob.ID, opts blob.ExtendOptions) error

ExtendBlobRetention provides a mock function with given fields: ctx, blobID, opts

func (*Storage) FlushCaches

func (_m *Storage) FlushCaches(ctx context.Context) error

FlushCaches provides a mock function with given fields: ctx

func (*Storage) GetBlob

func (_m *Storage) GetBlob(ctx context.Context, blobID blob.ID, offset int64, length int64, output blob.OutputBuffer) error

GetBlob provides a mock function with given fields: ctx, blobID, offset, length, output

func (*Storage) GetCapacity

func (_m *Storage) GetCapacity(ctx context.Context) (blob.Capacity, error)

GetCapacity provides a mock function with given fields: ctx

func (*Storage) GetMetadata

func (_m *Storage) GetMetadata(ctx context.Context, blobID blob.ID) (blob.Metadata, error)

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

func (*Storage) IsReadOnly added in v1.13.0

func (_m *Storage) IsReadOnly() bool

IsReadOnly provides a mock function with given fields:

func (*Storage) ListBlobs

func (_m *Storage) ListBlobs(ctx context.Context, blobIDPrefix blob.ID, cb func(blob.Metadata) error) error

ListBlobs provides a mock function with given fields: ctx, blobIDPrefix, cb

func (*Storage) PutBlob

func (_m *Storage) PutBlob(ctx context.Context, blobID blob.ID, data blob.Bytes, opts blob.PutOptions) error

PutBlob provides a mock function with given fields: ctx, blobID, data, opts

type Store

type Store struct {
	mock.Mock
}

Store is an autogenerated mock type for the Store type

func NewStore

func NewStore(t mockConstructorTestingTNewStore) *Store

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

func (*Store) Connect

func (_m *Store) Connect(ctx context.Context, isCreate bool) (blob.Storage, error)

Connect provides a mock function with given fields: ctx, isCreate

func (*Store) Setup

func (_m *Store) Setup(ctx context.Context, flags map[string]string) error

Setup provides a mock function with given fields: ctx, flags

type Writer added in v1.12.0

type Writer struct {
	mock.Mock
}

Writer is an autogenerated mock type for the Writer type

func NewWriter added in v1.12.0

func NewWriter(t mockConstructorTestingTNewWriter) *Writer

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

func (*Writer) Checkpoint added in v1.12.0

func (_m *Writer) Checkpoint() (object.ID, error)

Checkpoint provides a mock function with given fields:

func (*Writer) Close added in v1.12.0

func (_m *Writer) Close() error

Close provides a mock function with given fields:

func (*Writer) Result added in v1.12.0

func (_m *Writer) Result() (object.ID, error)

Result provides a mock function with given fields:

func (*Writer) Write added in v1.12.0

func (_m *Writer) Write(p []byte) (int, error)

Write provides a mock function with given fields: p

Jump to

Keyboard shortcuts

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