mounttest

package
v1.50.17 Latest Latest
Warning

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

Go to latest
Published: Mar 10, 2020 License: MIT Imports: 24 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FIXMETestWriteOpenFileInDirListing

func FIXMETestWriteOpenFileInDirListing(t *testing.T)

FIXMETestWriteOpenFileInDirListing tests open file in directory listing

func RunTests

func RunTests(t *testing.T, fn MountFn)

RunTests runs all the tests against all the VFS cache modes

func TestDirCacheFlush

func TestDirCacheFlush(t *testing.T)

TestDirCacheFlush tests fluching the dir cache

func TestDirCacheFlushOnDirRename

func TestDirCacheFlushOnDirRename(t *testing.T)

TestDirCacheFlushOnDirRename tests flushing the dir cache on rename

func TestDirCreateAndRemoveDir

func TestDirCreateAndRemoveDir(t *testing.T)

TestDirCreateAndRemoveDir tests creating and removing a directory

func TestDirCreateAndRemoveFile

func TestDirCreateAndRemoveFile(t *testing.T)

TestDirCreateAndRemoveFile tests creating and removing a file

func TestDirLs

func TestDirLs(t *testing.T)

TestDirLs checks out listing

func TestDirModTime

func TestDirModTime(t *testing.T)

TestDirModTime tests mod times

func TestDirRenameEmptyDir

func TestDirRenameEmptyDir(t *testing.T)

TestDirRenameEmptyDir tests renaming and empty directory

func TestDirRenameFile

func TestDirRenameFile(t *testing.T)

TestDirRenameFile tests renaming a file

func TestDirRenameFullDir

func TestDirRenameFullDir(t *testing.T)

TestDirRenameFullDir tests renaming a full directory

func TestFileModTime

func TestFileModTime(t *testing.T)

TestFileModTime tests mod times on files

func TestFileModTimeWithOpenWriters

func TestFileModTimeWithOpenWriters(t *testing.T)

TestFileModTimeWithOpenWriters tests mod time on open files

func TestMount

func TestMount(t *testing.T)

TestMount checks that the Fs is mounted by seeing if the mountpoint is in the mount output

func TestReadByByte

func TestReadByByte(t *testing.T)

TestReadByByte reads by byte including don't read any bytes

func TestReadChecksum

func TestReadChecksum(t *testing.T)

TestReadChecksum checks the checksum reading is working

func TestReadFileDoubleClose

func TestReadFileDoubleClose(t *testing.T)

TestReadFileDoubleClose tests double close on read

func TestReadSeek

func TestReadSeek(t *testing.T)

TestReadSeek test seeking

func TestRenameOpenHandle

func TestRenameOpenHandle(t *testing.T)

TestRenameOpenHandle checks that a file with open writers is successfully renamed after all writers close. See https://github.com/artpar/rclone/issues/2130

func TestRoot

func TestRoot(t *testing.T)

TestRoot checks root directory is present and correct

func TestTouchAndDelete

func TestTouchAndDelete(t *testing.T)

TestTouchAndDelete checks that writing a zero byte file and immediately deleting it is not racy. See https://github.com/artpar/rclone/issues/1181

func TestWriteFileAppend added in v1.6.1

func TestWriteFileAppend(t *testing.T)

TestWriteFileAppend tests that O_APPEND works on cache backends >= writes

func TestWriteFileDoubleClose

func TestWriteFileDoubleClose(t *testing.T)

TestWriteFileDoubleClose tests double close on write

func TestWriteFileDup added in v1.6.1

func TestWriteFileDup(t *testing.T)

TestWriteFileDup tests behavior of mmap() in Python by using dup() on a file handle

func TestWriteFileFsync

func TestWriteFileFsync(t *testing.T)

TestWriteFileFsync tests Fsync

NB the code for this is in file.go rather than write.go

func TestWriteFileNoWrite

func TestWriteFileNoWrite(t *testing.T)

TestWriteFileNoWrite tests writing a file with no write()'s to it

func TestWriteFileOverwrite

func TestWriteFileOverwrite(t *testing.T)

TestWriteFileOverwrite tests overwriting a file

func TestWriteFileWrite

func TestWriteFileWrite(t *testing.T)

TestWriteFileWrite tests writing a file and reading it back

Types

type MountFn

type MountFn func(f fs.Fs, mountpoint string) (*vfs.VFS, <-chan error, func() error, error)

MountFn is called to mount the file system

type Run

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

Run holds the remotes for a test run

func (*Run) Finalise

func (r *Run) Finalise()

Finalise cleans the remote and unmounts

type UnmountFn

type UnmountFn func() error

UnmountFn is called to unmount the file system

Jump to

Keyboard shortcuts

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