Documentation ¶
Index ¶
- type FakeFileSystem
- func (fs *FakeFileSystem) ChownForEmulator(filePath string, recursive bool) error
- func (fs *FakeFileSystem) GetDelimitedReader(path string) (fs.DelimitedReader, error)
- func (fs *FakeFileSystem) IsPathAnNs(path string) bool
- func (fs *FakeFileSystem) Mount(source string, target string, fstype string, bind bool) error
- func (fs *FakeFileSystem) Unmount(target string, detach bool) error
- func (fs *FakeFileSystem) WriteFile(path string, data []byte, perm os.FileMode) error
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type FakeFileSystem ¶
type FakeFileSystem struct {
// contains filtered or unexported fields
}
FakeFileSystem is a fake implementation of FileSystem interface that uses a Recorder to record the operations performed on it.
func NewFakeFileSystem ¶
func NewFakeFileSystem(t *testing.T, rec testutils.Recorder, mountParentDir string, files map[string]string) *FakeFileSystem
NewFakeFileSystem creates a new instance of FakeFileSystem using the provided recorder and a directory that should be parent for all the fake mountpoints. It also takes map with fake files that will be accessible with GetDelimitedReader (besides those written with WriteFile).
func (*FakeFileSystem) ChownForEmulator ¶
func (fs *FakeFileSystem) ChownForEmulator(filePath string, recursive bool) error
ChownForEmulator implements ChownForEmulator method of FileSystem interface.
func (*FakeFileSystem) GetDelimitedReader ¶
func (fs *FakeFileSystem) GetDelimitedReader(path string) (fs.DelimitedReader, error)
GetDelimitedReader implements the FileReader method of FileSystem interface.
func (*FakeFileSystem) IsPathAnNs ¶
func (fs *FakeFileSystem) IsPathAnNs(path string) bool
IsPathAnNs implements the IsPathAnNs method of FileSystem interface.
Click to show internal directories.
Click to hide internal directories.