Documentation
¶
Overview ¶
Package fakefs provides a fake file system implementation for testing.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FakeFileInfo ¶
type FakeFileInfo struct {
FileName string
FileSize int64
FileMode fs.FileMode
FileModTime time.Time
}
FakeFileInfo is a fake implementation of fs.FileInfo.
func (FakeFileInfo) IsDir ¶
func (i FakeFileInfo) IsDir() bool
IsDir returns true if the file is a directory.
func (FakeFileInfo) ModTime ¶
func (i FakeFileInfo) ModTime() time.Time
ModTime returns the modification time of the file.
func (FakeFileInfo) Mode ¶
func (i FakeFileInfo) Mode() fs.FileMode
Mode returns the mode of the file.
func (FakeFileInfo) Sys ¶
func (i FakeFileInfo) Sys() any
Sys is an implementation of FileInfo.Sys() that returns nothing (nil).
type MockEvalSymlinksFS ¶ added in v0.3.2
MockEvalSymlinksFS is a mock implementation of image.EvalSymlinksFS for testing.
func NewMockEvalSymlinksFS ¶ added in v0.3.2
func NewMockEvalSymlinksFS(fs scalibrfs.FS, symlinks map[string]string) *MockEvalSymlinksFS
NewMockEvalSymlinksFS creates a new MockEvalSymlinksFS.
func (*MockEvalSymlinksFS) EvalSymlink ¶ added in v0.3.2
func (fs *MockEvalSymlinksFS) EvalSymlink(name string) (string, error)
EvalSymlink mocks the evaluation of symlinks.
Click to show internal directories.
Click to hide internal directories.