hostiface

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Mar 28, 2020 License: MIT Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CommandAPI

type CommandAPI interface {
	Run() error
	CombinedOutput() ([]byte, error)
	Output() ([]byte, error)
}

CommandAPI represents a command.

type ExecAPI

type ExecAPI interface {
	Command(name string, arg ...string) CommandAPI
}

ExecAPI represents anything that knows how to build a command.

type FileInfo

type FileInfo interface {
	os.FileInfo
}

FileInfo is a wrapper around the os.FileInfo interface. Mockery isn't very good at making mocks for interfaces outside of the project, so I'm wrapping the FileInfo interface to make life a bit easier.

type OSIOAPI

type OSIOAPI interface {
	ReadFile(filename string) ([]byte, error)
	WriteFile(filename string, data []byte, perm os.FileMode) error
	ReadDir(dirname string) ([]os.FileInfo, error)
	LookupEnv(key string) (string, bool)
}

OSIOAPI represents something that provides OS and IO methods.

Source Files

  • execapi.go
  • osio.go

Jump to

Keyboard shortcuts

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