mocks

package
v1.0.48 Latest Latest
Warning

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

Go to latest
Published: Mar 3, 2023 License: BSD-3-Clause Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Bucket

type Bucket struct {
	mock.Mock
}

Bucket is an autogenerated mock type for the Bucket type

func NewBucket added in v0.0.58

func NewBucket(t mockConstructorTestingTNewBucket) *Bucket

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

func (*Bucket) Attrs

func (_m *Bucket) Attrs(objectName string) (*storage.ObjectAttrs, error)

Attrs provides a mock function with given fields: objectName

func (*Bucket) Close

func (_m *Bucket) Close() error

Close provides a mock function with given fields:

func (*Bucket) Delete

func (_m *Bucket) Delete(objectName string) error

Delete provides a mock function with given fields: objectName

func (*Bucket) Download

func (_m *Bucket) Download(objectName string, localPath string) error

Download provides a mock function with given fields: objectName, localPath

func (*Bucket) EXPECT added in v1.0.8

func (_m *Bucket) EXPECT() *Bucket_Expecter

func (*Bucket) Exists

func (_m *Bucket) Exists(objectName string) (bool, error)

Exists provides a mock function with given fields: objectName

func (*Bucket) Name

func (_m *Bucket) Name() string

Name provides a mock function with given fields:

func (*Bucket) NewLocker

func (_m *Bucket) NewLocker(objectName string, maxWait time.Duration, options ...bucket.LockerOption) bucket.Locker

NewLocker provides a mock function with given fields: objectName, maxWait, options

func (*Bucket) Read

func (_m *Bucket) Read(objectName string) ([]byte, error)

Read provides a mock function with given fields: objectName

func (*Bucket) Update

func (_m *Bucket) Update(objectName string, attrs ...object.AttrSetter) error

Update provides a mock function with given fields: objectName, attrs

func (*Bucket) Upload

func (_m *Bucket) Upload(localPath string, objectName string, attrs ...object.AttrSetter) error

Upload provides a mock function with given fields: localPath, objectName, attrs

func (*Bucket) Write

func (_m *Bucket) Write(objectName string, content []byte, attrs ...object.AttrSetter) error

Write provides a mock function with given fields: objectName, content, attrs

func (*Bucket) WriteFromStream added in v1.0.8

func (_m *Bucket) WriteFromStream(objectName string, reader io.Reader, attrs ...object.AttrSetter) error

WriteFromStream provides a mock function with given fields: objectName, reader, attrs

func (*Bucket) Writer added in v1.0.8

func (_m *Bucket) Writer(objectName string) io.WriteCloser

Writer provides a mock function with given fields: objectName

type Bucket_Attrs_Call added in v1.0.8

type Bucket_Attrs_Call struct {
	*mock.Call
}

Bucket_Attrs_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Attrs'

func (*Bucket_Attrs_Call) Return added in v1.0.8

func (*Bucket_Attrs_Call) Run added in v1.0.8

func (_c *Bucket_Attrs_Call) Run(run func(objectName string)) *Bucket_Attrs_Call

type Bucket_Close_Call added in v1.0.8

type Bucket_Close_Call struct {
	*mock.Call
}

Bucket_Close_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Close'

func (*Bucket_Close_Call) Return added in v1.0.8

func (_c *Bucket_Close_Call) Return(_a0 error) *Bucket_Close_Call

func (*Bucket_Close_Call) Run added in v1.0.8

func (_c *Bucket_Close_Call) Run(run func()) *Bucket_Close_Call

type Bucket_Delete_Call added in v1.0.8

type Bucket_Delete_Call struct {
	*mock.Call
}

Bucket_Delete_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Delete'

func (*Bucket_Delete_Call) Return added in v1.0.8

func (_c *Bucket_Delete_Call) Return(_a0 error) *Bucket_Delete_Call

func (*Bucket_Delete_Call) Run added in v1.0.8

func (_c *Bucket_Delete_Call) Run(run func(objectName string)) *Bucket_Delete_Call

type Bucket_Download_Call added in v1.0.8

type Bucket_Download_Call struct {
	*mock.Call
}

Bucket_Download_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Download'

func (*Bucket_Download_Call) Return added in v1.0.8

func (*Bucket_Download_Call) Run added in v1.0.8

func (_c *Bucket_Download_Call) Run(run func(objectName string, localPath string)) *Bucket_Download_Call

type Bucket_Exists_Call added in v1.0.8

type Bucket_Exists_Call struct {
	*mock.Call
}

Bucket_Exists_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Exists'

func (*Bucket_Exists_Call) Return added in v1.0.8

func (_c *Bucket_Exists_Call) Return(_a0 bool, _a1 error) *Bucket_Exists_Call

func (*Bucket_Exists_Call) Run added in v1.0.8

func (_c *Bucket_Exists_Call) Run(run func(objectName string)) *Bucket_Exists_Call

type Bucket_Expecter added in v1.0.8

type Bucket_Expecter struct {
	// contains filtered or unexported fields
}

func (*Bucket_Expecter) Attrs added in v1.0.8

func (_e *Bucket_Expecter) Attrs(objectName interface{}) *Bucket_Attrs_Call

Attrs is a helper method to define mock.On call

  • objectName string

func (*Bucket_Expecter) Close added in v1.0.8

func (_e *Bucket_Expecter) Close() *Bucket_Close_Call

Close is a helper method to define mock.On call

func (*Bucket_Expecter) Delete added in v1.0.8

func (_e *Bucket_Expecter) Delete(objectName interface{}) *Bucket_Delete_Call

Delete is a helper method to define mock.On call

  • objectName string

func (*Bucket_Expecter) Download added in v1.0.8

func (_e *Bucket_Expecter) Download(objectName interface{}, localPath interface{}) *Bucket_Download_Call

Download is a helper method to define mock.On call

  • objectName string
  • localPath string

func (*Bucket_Expecter) Exists added in v1.0.8

func (_e *Bucket_Expecter) Exists(objectName interface{}) *Bucket_Exists_Call

Exists is a helper method to define mock.On call

  • objectName string

func (*Bucket_Expecter) Name added in v1.0.8

func (_e *Bucket_Expecter) Name() *Bucket_Name_Call

Name is a helper method to define mock.On call

func (*Bucket_Expecter) NewLocker added in v1.0.8

func (_e *Bucket_Expecter) NewLocker(objectName interface{}, maxWait interface{}, options ...interface{}) *Bucket_NewLocker_Call

NewLocker is a helper method to define mock.On call

  • objectName string
  • maxWait time.Duration
  • options ...bucket.LockerOption

func (*Bucket_Expecter) Read added in v1.0.8

func (_e *Bucket_Expecter) Read(objectName interface{}) *Bucket_Read_Call

Read is a helper method to define mock.On call

  • objectName string

func (*Bucket_Expecter) Update added in v1.0.8

func (_e *Bucket_Expecter) Update(objectName interface{}, attrs ...interface{}) *Bucket_Update_Call

Update is a helper method to define mock.On call

  • objectName string
  • attrs ...object.AttrSetter

func (*Bucket_Expecter) Upload added in v1.0.8

func (_e *Bucket_Expecter) Upload(localPath interface{}, objectName interface{}, attrs ...interface{}) *Bucket_Upload_Call

Upload is a helper method to define mock.On call

  • localPath string
  • objectName string
  • attrs ...object.AttrSetter

func (*Bucket_Expecter) Write added in v1.0.8

func (_e *Bucket_Expecter) Write(objectName interface{}, content interface{}, attrs ...interface{}) *Bucket_Write_Call

Write is a helper method to define mock.On call

  • objectName string
  • content []byte
  • attrs ...object.AttrSetter

func (*Bucket_Expecter) WriteFromStream added in v1.0.8

func (_e *Bucket_Expecter) WriteFromStream(objectName interface{}, reader interface{}, attrs ...interface{}) *Bucket_WriteFromStream_Call

WriteFromStream is a helper method to define mock.On call

  • objectName string
  • reader io.Reader
  • attrs ...object.AttrSetter

func (*Bucket_Expecter) Writer added in v1.0.8

func (_e *Bucket_Expecter) Writer(objectName interface{}) *Bucket_Writer_Call

Writer is a helper method to define mock.On call

  • objectName string

type Bucket_Name_Call added in v1.0.8

type Bucket_Name_Call struct {
	*mock.Call
}

Bucket_Name_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Name'

func (*Bucket_Name_Call) Return added in v1.0.8

func (_c *Bucket_Name_Call) Return(_a0 string) *Bucket_Name_Call

func (*Bucket_Name_Call) Run added in v1.0.8

func (_c *Bucket_Name_Call) Run(run func()) *Bucket_Name_Call

type Bucket_NewLocker_Call added in v1.0.8

type Bucket_NewLocker_Call struct {
	*mock.Call
}

Bucket_NewLocker_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'NewLocker'

func (*Bucket_NewLocker_Call) Return added in v1.0.8

func (*Bucket_NewLocker_Call) Run added in v1.0.8

func (_c *Bucket_NewLocker_Call) Run(run func(objectName string, maxWait time.Duration, options ...bucket.LockerOption)) *Bucket_NewLocker_Call

type Bucket_Read_Call added in v1.0.8

type Bucket_Read_Call struct {
	*mock.Call
}

Bucket_Read_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Read'

func (*Bucket_Read_Call) Return added in v1.0.8

func (_c *Bucket_Read_Call) Return(_a0 []byte, _a1 error) *Bucket_Read_Call

func (*Bucket_Read_Call) Run added in v1.0.8

func (_c *Bucket_Read_Call) Run(run func(objectName string)) *Bucket_Read_Call

type Bucket_Update_Call added in v1.0.8

type Bucket_Update_Call struct {
	*mock.Call
}

Bucket_Update_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Update'

func (*Bucket_Update_Call) Return added in v1.0.8

func (_c *Bucket_Update_Call) Return(_a0 error) *Bucket_Update_Call

func (*Bucket_Update_Call) Run added in v1.0.8

func (_c *Bucket_Update_Call) Run(run func(objectName string, attrs ...object.AttrSetter)) *Bucket_Update_Call

type Bucket_Upload_Call added in v1.0.8

type Bucket_Upload_Call struct {
	*mock.Call
}

Bucket_Upload_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Upload'

func (*Bucket_Upload_Call) Return added in v1.0.8

func (_c *Bucket_Upload_Call) Return(_a0 error) *Bucket_Upload_Call

func (*Bucket_Upload_Call) Run added in v1.0.8

func (_c *Bucket_Upload_Call) Run(run func(localPath string, objectName string, attrs ...object.AttrSetter)) *Bucket_Upload_Call

type Bucket_WriteFromStream_Call added in v1.0.8

type Bucket_WriteFromStream_Call struct {
	*mock.Call
}

Bucket_WriteFromStream_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'WriteFromStream'

func (*Bucket_WriteFromStream_Call) Return added in v1.0.8

func (*Bucket_WriteFromStream_Call) Run added in v1.0.8

func (_c *Bucket_WriteFromStream_Call) Run(run func(objectName string, reader io.Reader, attrs ...object.AttrSetter)) *Bucket_WriteFromStream_Call

type Bucket_Write_Call added in v1.0.8

type Bucket_Write_Call struct {
	*mock.Call
}

Bucket_Write_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Write'

func (*Bucket_Write_Call) Return added in v1.0.8

func (_c *Bucket_Write_Call) Return(_a0 error) *Bucket_Write_Call

func (*Bucket_Write_Call) Run added in v1.0.8

func (_c *Bucket_Write_Call) Run(run func(objectName string, content []byte, attrs ...object.AttrSetter)) *Bucket_Write_Call

type Bucket_Writer_Call added in v1.0.8

type Bucket_Writer_Call struct {
	*mock.Call
}

Bucket_Writer_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Writer'

func (*Bucket_Writer_Call) Return added in v1.0.8

func (*Bucket_Writer_Call) Run added in v1.0.8

func (_c *Bucket_Writer_Call) Run(run func(objectName string)) *Bucket_Writer_Call

type Locker

type Locker struct {
	mock.Mock
}

Locker is an autogenerated mock type for the Locker type

func NewLocker added in v0.0.58

func NewLocker(t mockConstructorTestingTNewLocker) *Locker

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

func (*Locker) EXPECT added in v1.0.8

func (_m *Locker) EXPECT() *Locker_Expecter

func (*Locker) Lock

func (_m *Locker) Lock() (int64, error)

Lock provides a mock function with given fields:

func (*Locker) ObjectName

func (_m *Locker) ObjectName() string

ObjectName provides a mock function with given fields:

func (*Locker) Unlock

func (_m *Locker) Unlock(lockId int64) error

Unlock provides a mock function with given fields: lockId

type Locker_Expecter added in v1.0.8

type Locker_Expecter struct {
	// contains filtered or unexported fields
}

func (*Locker_Expecter) Lock added in v1.0.8

func (_e *Locker_Expecter) Lock() *Locker_Lock_Call

Lock is a helper method to define mock.On call

func (*Locker_Expecter) ObjectName added in v1.0.8

func (_e *Locker_Expecter) ObjectName() *Locker_ObjectName_Call

ObjectName is a helper method to define mock.On call

func (*Locker_Expecter) Unlock added in v1.0.8

func (_e *Locker_Expecter) Unlock(lockId interface{}) *Locker_Unlock_Call

Unlock is a helper method to define mock.On call

  • lockId int64

type Locker_Lock_Call added in v1.0.8

type Locker_Lock_Call struct {
	*mock.Call
}

Locker_Lock_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Lock'

func (*Locker_Lock_Call) Return added in v1.0.8

func (_c *Locker_Lock_Call) Return(_a0 int64, _a1 error) *Locker_Lock_Call

func (*Locker_Lock_Call) Run added in v1.0.8

func (_c *Locker_Lock_Call) Run(run func()) *Locker_Lock_Call

type Locker_ObjectName_Call added in v1.0.8

type Locker_ObjectName_Call struct {
	*mock.Call
}

Locker_ObjectName_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'ObjectName'

func (*Locker_ObjectName_Call) Return added in v1.0.8

func (*Locker_ObjectName_Call) Run added in v1.0.8

func (_c *Locker_ObjectName_Call) Run(run func()) *Locker_ObjectName_Call

type Locker_Unlock_Call added in v1.0.8

type Locker_Unlock_Call struct {
	*mock.Call
}

Locker_Unlock_Call is a *mock.Call that shadows Run/Return methods with type explicit version for method 'Unlock'

func (*Locker_Unlock_Call) Return added in v1.0.8

func (_c *Locker_Unlock_Call) Return(_a0 error) *Locker_Unlock_Call

func (*Locker_Unlock_Call) Run added in v1.0.8

func (_c *Locker_Unlock_Call) Run(run func(lockId int64)) *Locker_Unlock_Call

Jump to

Keyboard shortcuts

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