mocks

package
v1.2.1 Latest Latest
Warning

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

Go to latest
Published: Aug 10, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type MockFilesystem

type MockFilesystem struct {
	mock.Mock
}

MockFilesystem is an autogenerated mock type for the Filesystem type

func NewMockFilesystem

func NewMockFilesystem(t interface {
	mock.TestingT
	Cleanup(func())
}) *MockFilesystem

NewMockFilesystem creates a new instance of MockFilesystem. 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 (*MockFilesystem) EXPECT

func (*MockFilesystem) ReadFile

func (_m *MockFilesystem) ReadFile(name string) ([]byte, error)

ReadFile provides a mock function with given fields: name

func (*MockFilesystem) Stat

func (_m *MockFilesystem) Stat(name string) (fs.FileInfo, error)

Stat provides a mock function with given fields: name

func (*MockFilesystem) WriteFile

func (_m *MockFilesystem) WriteFile(name string, data []byte, perm fs.FileMode) error

WriteFile provides a mock function with given fields: name, data, perm

type MockFilesystem_Expecter

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

func (*MockFilesystem_Expecter) ReadFile

func (_e *MockFilesystem_Expecter) ReadFile(name interface{}) *MockFilesystem_ReadFile_Call

ReadFile is a helper method to define mock.On call

  • name string

func (*MockFilesystem_Expecter) Stat

func (_e *MockFilesystem_Expecter) Stat(name interface{}) *MockFilesystem_Stat_Call

Stat is a helper method to define mock.On call

  • name string

func (*MockFilesystem_Expecter) WriteFile

func (_e *MockFilesystem_Expecter) WriteFile(name interface{}, data interface{}, perm interface{}) *MockFilesystem_WriteFile_Call

WriteFile is a helper method to define mock.On call

  • name string
  • data []byte
  • perm fs.FileMode

type MockFilesystem_ReadFile_Call

type MockFilesystem_ReadFile_Call struct {
	*mock.Call
}

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

func (*MockFilesystem_ReadFile_Call) Return

func (*MockFilesystem_ReadFile_Call) Run

func (*MockFilesystem_ReadFile_Call) RunAndReturn

type MockFilesystem_Stat_Call

type MockFilesystem_Stat_Call struct {
	*mock.Call
}

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

func (*MockFilesystem_Stat_Call) Return

func (*MockFilesystem_Stat_Call) Run

func (_c *MockFilesystem_Stat_Call) Run(run func(name string)) *MockFilesystem_Stat_Call

func (*MockFilesystem_Stat_Call) RunAndReturn

func (_c *MockFilesystem_Stat_Call) RunAndReturn(run func(string) (fs.FileInfo, error)) *MockFilesystem_Stat_Call

type MockFilesystem_WriteFile_Call

type MockFilesystem_WriteFile_Call struct {
	*mock.Call
}

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

func (*MockFilesystem_WriteFile_Call) Return

func (*MockFilesystem_WriteFile_Call) Run

func (_c *MockFilesystem_WriteFile_Call) Run(run func(name string, data []byte, perm fs.FileMode)) *MockFilesystem_WriteFile_Call

func (*MockFilesystem_WriteFile_Call) RunAndReturn

Jump to

Keyboard shortcuts

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