fixtures

package
v0.0.0-...-eedcae6 Latest Latest
Warning

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

Go to latest
Published: Nov 20, 2015 License: MIT Imports: 21 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CleanInput

func CleanInput(in string) (out io.Reader)

Clean input and return new reader

func FixStream

func FixStream(in string) (res string)

func GetLocalIPv4

func GetLocalIPv4() (ipv4 net.IP, err error)

Get local IPv4

func GetOpenPort

func GetOpenPort() (p int, err error)

func GetOpenPorts

func GetOpenPorts(n int) (p []int, err error)

func KillBLOB

func KillBLOB(name string) (err error)

func MakeBLOB

func MakeBLOB(t *testing.T, size int64) (name string)

Make temporary BLOB

func MakeBLOBPure

func MakeBLOBPure(size int64) (name string, err error)

func MakeNamedBLOB

func MakeNamedBLOB(name string, size int64) (err error)

func NewShadowFromFile

func NewShadowFromFile(filename string) (res *proto.Manifest, err error)

func ServerStoredName

func ServerStoredName(root string, id string) string

Types

type FixtureServer

type FixtureServer struct {
	server.Server
	*proto.ServerInfo
	Root string
}

func NewFixtureServer

func NewFixtureServer(name string) (res *FixtureServer, err error)

func (*FixtureServer) Stop

func (s *FixtureServer) Stop()

type Tree

type Tree struct {
	CWD string
}

func NewTree

func NewTree(where, wd string) *Tree

func (*Tree) BlobFilename

func (f *Tree) BlobFilename(n string) string

func (*Tree) KillBLOB

func (f *Tree) KillBLOB(name string) (err error)

func (*Tree) Populate

func (f *Tree) Populate() (err error)

func (*Tree) PopulateN

func (f *Tree) PopulateN(size int64, n int) (err error)

func (*Tree) Squash

func (f *Tree) Squash() (err error)

func (*Tree) WriteBLOB

func (f *Tree) WriteBLOB(name string, size int64) (err error)

Directories

Path Synopsis
protos
pb3
Package bar is a generated protocol buffer package.
Package bar is a generated protocol buffer package.

Jump to

Keyboard shortcuts

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