mock

package
v0.0.0-...-a1f2fe4 Latest Latest
Warning

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

Go to latest
Published: Nov 28, 2017 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 FakeFileUtil

type FakeFileUtil struct {
	ReadContent  map[string][]byte
	WriteContent map[string][]byte
}

FakeFileUtil is a mocked FileUtil for testing.

func (FakeFileUtil) Read

func (f FakeFileUtil) Read(filename string) ([]byte, error)

Read returns the filename entry in ReadContent or an error.

func (FakeFileUtil) Write

func (f FakeFileUtil) Write(filename string, content []byte, perm os.FileMode) error

Write writes data to the filename entry in WriteContent.

Jump to

Keyboard shortcuts

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