Documentation ¶
Index ¶
- func SanitizeFileName(name string) string
- type TempDirFixture
- func (f *TempDirFixture) Chdir()
- func (f *TempDirFixture) CopyFile(originalPath, newPath string)
- func (f *TempDirFixture) JoinPath(path ...string) string
- func (f *TempDirFixture) JoinPaths(paths []string) []string
- func (f *TempDirFixture) MkdirAll(path string)
- func (f *TempDirFixture) NewFile(prefix string) (*os.File, error)
- func (f *TempDirFixture) Path() string
- func (f *TempDirFixture) ReadFile(path string) string
- func (f *TempDirFixture) Rm(pathInRepo string)
- func (f *TempDirFixture) T() testing.TB
- func (f *TempDirFixture) TempDir(prefix string) string
- func (f *TempDirFixture) TouchFiles(paths []string)
- func (f *TempDirFixture) WriteFile(path string, contents string) string
- func (f *TempDirFixture) WriteSymlink(linkContents, destPath string)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SanitizeFileName ¶ added in v0.14.0
Types ¶
type TempDirFixture ¶
type TempDirFixture struct {
// contains filtered or unexported fields
}
func NewTempDirFixture ¶
func NewTempDirFixture(t testing.TB) *TempDirFixture
func (*TempDirFixture) Chdir ¶ added in v0.14.0
func (f *TempDirFixture) Chdir()
func (*TempDirFixture) CopyFile ¶ added in v0.9.7
func (f *TempDirFixture) CopyFile(originalPath, newPath string)
Returns the full path to the file written.
func (*TempDirFixture) JoinPath ¶
func (f *TempDirFixture) JoinPath(path ...string) string
func (*TempDirFixture) JoinPaths ¶
func (f *TempDirFixture) JoinPaths(paths []string) []string
func (*TempDirFixture) MkdirAll ¶
func (f *TempDirFixture) MkdirAll(path string)
func (*TempDirFixture) Path ¶
func (f *TempDirFixture) Path() string
func (*TempDirFixture) ReadFile ¶ added in v0.23.5
func (f *TempDirFixture) ReadFile(path string) string
Read the file.
func (*TempDirFixture) Rm ¶
func (f *TempDirFixture) Rm(pathInRepo string)
func (*TempDirFixture) T ¶
func (f *TempDirFixture) T() testing.TB
func (*TempDirFixture) TempDir ¶ added in v0.4.1
func (f *TempDirFixture) TempDir(prefix string) string
func (*TempDirFixture) TouchFiles ¶
func (f *TempDirFixture) TouchFiles(paths []string)
func (*TempDirFixture) WriteFile ¶
func (f *TempDirFixture) WriteFile(path string, contents string) string
Returns the full path to the file written.
func (*TempDirFixture) WriteSymlink ¶ added in v0.6.0
func (f *TempDirFixture) WriteSymlink(linkContents, destPath string)
Click to show internal directories.
Click to hide internal directories.