Documentation ¶
Index ¶
- type Bucket
- func (_m *Bucket) Attrs(objectName string) (*storage.ObjectAttrs, error)
- func (_m *Bucket) Close() error
- func (_m *Bucket) Delete(objectName string) error
- func (_m *Bucket) Download(objectName string, localPath string) error
- func (_m *Bucket) EXPECT() *Bucket_Expecter
- func (_m *Bucket) Exists(objectName string) (bool, error)
- func (_m *Bucket) Name() string
- func (_m *Bucket) NewLocker(objectName string, maxWait time.Duration, options ...bucket.LockerOption) bucket.Locker
- func (_m *Bucket) Read(objectName string) ([]byte, error)
- func (_m *Bucket) Update(objectName string, attrs ...object.AttrSetter) error
- func (_m *Bucket) Upload(localPath string, objectName string, attrs ...object.AttrSetter) error
- func (_m *Bucket) Write(objectName string, content []byte, attrs ...object.AttrSetter) error
- func (_m *Bucket) WriteFromStream(objectName string, reader io.Reader, attrs ...object.AttrSetter) error
- func (_m *Bucket) Writer(objectName string) io.WriteCloser
- type Bucket_Attrs_Call
- type Bucket_Close_Call
- type Bucket_Delete_Call
- type Bucket_Download_Call
- type Bucket_Exists_Call
- type Bucket_Expecter
- func (_e *Bucket_Expecter) Attrs(objectName interface{}) *Bucket_Attrs_Call
- func (_e *Bucket_Expecter) Close() *Bucket_Close_Call
- func (_e *Bucket_Expecter) Delete(objectName interface{}) *Bucket_Delete_Call
- func (_e *Bucket_Expecter) Download(objectName interface{}, localPath interface{}) *Bucket_Download_Call
- func (_e *Bucket_Expecter) Exists(objectName interface{}) *Bucket_Exists_Call
- func (_e *Bucket_Expecter) Name() *Bucket_Name_Call
- func (_e *Bucket_Expecter) NewLocker(objectName interface{}, maxWait interface{}, options ...interface{}) *Bucket_NewLocker_Call
- func (_e *Bucket_Expecter) Read(objectName interface{}) *Bucket_Read_Call
- func (_e *Bucket_Expecter) Update(objectName interface{}, attrs ...interface{}) *Bucket_Update_Call
- func (_e *Bucket_Expecter) Upload(localPath interface{}, objectName interface{}, attrs ...interface{}) *Bucket_Upload_Call
- func (_e *Bucket_Expecter) Write(objectName interface{}, content interface{}, attrs ...interface{}) *Bucket_Write_Call
- func (_e *Bucket_Expecter) WriteFromStream(objectName interface{}, reader interface{}, attrs ...interface{}) *Bucket_WriteFromStream_Call
- func (_e *Bucket_Expecter) Writer(objectName interface{}) *Bucket_Writer_Call
- type Bucket_Name_Call
- type Bucket_NewLocker_Call
- type Bucket_Read_Call
- type Bucket_Update_Call
- type Bucket_Upload_Call
- func (_c *Bucket_Upload_Call) Return(_a0 error) *Bucket_Upload_Call
- func (_c *Bucket_Upload_Call) Run(run func(localPath string, objectName string, attrs ...object.AttrSetter)) *Bucket_Upload_Call
- func (_c *Bucket_Upload_Call) RunAndReturn(run func(string, string, ...object.AttrSetter) error) *Bucket_Upload_Call
- type Bucket_WriteFromStream_Call
- func (_c *Bucket_WriteFromStream_Call) Return(_a0 error) *Bucket_WriteFromStream_Call
- func (_c *Bucket_WriteFromStream_Call) Run(run func(objectName string, reader io.Reader, attrs ...object.AttrSetter)) *Bucket_WriteFromStream_Call
- func (_c *Bucket_WriteFromStream_Call) RunAndReturn(run func(string, io.Reader, ...object.AttrSetter) error) *Bucket_WriteFromStream_Call
- type Bucket_Write_Call
- func (_c *Bucket_Write_Call) Return(_a0 error) *Bucket_Write_Call
- func (_c *Bucket_Write_Call) Run(run func(objectName string, content []byte, attrs ...object.AttrSetter)) *Bucket_Write_Call
- func (_c *Bucket_Write_Call) RunAndReturn(run func(string, []byte, ...object.AttrSetter) error) *Bucket_Write_Call
- type Bucket_Writer_Call
- type Locker
- type Locker_Expecter
- type Locker_Lock_Call
- type Locker_ObjectName_Call
- type Locker_Unlock_Call
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Bucket ¶
Bucket is an autogenerated mock type for the Bucket type
func NewBucket ¶ added in v0.0.58
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. The first argument is typically a *testing.T value.
func (*Bucket) Attrs ¶
func (_m *Bucket) Attrs(objectName string) (*storage.ObjectAttrs, error)
Attrs provides a mock function with given fields: objectName
func (*Bucket) Download ¶
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) 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) Update ¶
func (_m *Bucket) Update(objectName string, attrs ...object.AttrSetter) error
Update provides a mock function with given fields: objectName, attrs
func (*Bucket) Upload ¶
Upload provides a mock function with given fields: localPath, objectName, 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
type Bucket_Attrs_Call ¶ added in v1.0.8
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 (_c *Bucket_Attrs_Call) Return(_a0 *storage.ObjectAttrs, _a1 error) *Bucket_Attrs_Call
func (*Bucket_Attrs_Call) Run ¶ added in v1.0.8
func (_c *Bucket_Attrs_Call) Run(run func(objectName string)) *Bucket_Attrs_Call
func (*Bucket_Attrs_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Attrs_Call) RunAndReturn(run func(string) (*storage.ObjectAttrs, error)) *Bucket_Attrs_Call
type Bucket_Close_Call ¶ added in v1.0.8
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
func (*Bucket_Close_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Close_Call) RunAndReturn(run func() error) *Bucket_Close_Call
type Bucket_Delete_Call ¶ added in v1.0.8
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
func (*Bucket_Delete_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Delete_Call) RunAndReturn(run func(string) error) *Bucket_Delete_Call
type Bucket_Download_Call ¶ added in v1.0.8
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 (_c *Bucket_Download_Call) Return(_a0 error) *Bucket_Download_Call
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
func (*Bucket_Download_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Download_Call) RunAndReturn(run func(string, string) error) *Bucket_Download_Call
type Bucket_Exists_Call ¶ added in v1.0.8
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
func (*Bucket_Exists_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Exists_Call) RunAndReturn(run func(string) (bool, error)) *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
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
func (*Bucket_Name_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Name_Call) RunAndReturn(run func() string) *Bucket_Name_Call
type Bucket_NewLocker_Call ¶ added in v1.0.8
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 (_c *Bucket_NewLocker_Call) Return(_a0 bucket.Locker) *Bucket_NewLocker_Call
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
func (*Bucket_NewLocker_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_NewLocker_Call) RunAndReturn(run func(string, time.Duration, ...bucket.LockerOption) bucket.Locker) *Bucket_NewLocker_Call
type Bucket_Read_Call ¶ added in v1.0.8
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
func (*Bucket_Read_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Read_Call) RunAndReturn(run func(string) ([]byte, error)) *Bucket_Read_Call
type Bucket_Update_Call ¶ added in v1.0.8
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
func (*Bucket_Update_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Update_Call) RunAndReturn(run func(string, ...object.AttrSetter) error) *Bucket_Update_Call
type Bucket_Upload_Call ¶ added in v1.0.8
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
func (*Bucket_Upload_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Upload_Call) RunAndReturn(run func(string, string, ...object.AttrSetter) error) *Bucket_Upload_Call
type Bucket_WriteFromStream_Call ¶ added in v1.0.8
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 (_c *Bucket_WriteFromStream_Call) Return(_a0 error) *Bucket_WriteFromStream_Call
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
func (*Bucket_WriteFromStream_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_WriteFromStream_Call) RunAndReturn(run func(string, io.Reader, ...object.AttrSetter) error) *Bucket_WriteFromStream_Call
type Bucket_Write_Call ¶ added in v1.0.8
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
func (*Bucket_Write_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Write_Call) RunAndReturn(run func(string, []byte, ...object.AttrSetter) error) *Bucket_Write_Call
type Bucket_Writer_Call ¶ added in v1.0.8
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 (_c *Bucket_Writer_Call) Return(_a0 io.WriteCloser) *Bucket_Writer_Call
func (*Bucket_Writer_Call) Run ¶ added in v1.0.8
func (_c *Bucket_Writer_Call) Run(run func(objectName string)) *Bucket_Writer_Call
func (*Bucket_Writer_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Bucket_Writer_Call) RunAndReturn(run func(string) io.WriteCloser) *Bucket_Writer_Call
type Locker ¶
Locker is an autogenerated mock type for the Locker type
func NewLocker ¶ added in v0.0.58
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. The first argument is typically a *testing.T value.
func (*Locker) EXPECT ¶ added in v1.0.8
func (_m *Locker) EXPECT() *Locker_Expecter
func (*Locker) ObjectName ¶
ObjectName provides a mock function with given fields:
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
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
func (*Locker_Lock_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Locker_Lock_Call) RunAndReturn(run func() (int64, error)) *Locker_Lock_Call
type Locker_ObjectName_Call ¶ added in v1.0.8
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 (_c *Locker_ObjectName_Call) Return(_a0 string) *Locker_ObjectName_Call
func (*Locker_ObjectName_Call) Run ¶ added in v1.0.8
func (_c *Locker_ObjectName_Call) Run(run func()) *Locker_ObjectName_Call
func (*Locker_ObjectName_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Locker_ObjectName_Call) RunAndReturn(run func() string) *Locker_ObjectName_Call
type Locker_Unlock_Call ¶ added in v1.0.8
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
func (*Locker_Unlock_Call) RunAndReturn ¶ added in v1.0.73
func (_c *Locker_Unlock_Call) RunAndReturn(run func(int64) error) *Locker_Unlock_Call