context

package
v0.12.3 Latest Latest
Warning

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

Go to latest
Published: Feb 13, 2022 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ExitCode

func ExitCode(exitCode int) runOptionsFn

func StripAnsi

func StripAnsi(str string) string

func StripAnsiSlice

func StripAnsiSlice(slice []string) []string

func Timeout

func Timeout(dur time.Duration) runOptionsFn

Types

type Config

type Config struct {
	ShellName   string
	BinaryPath  string
	DockerImage string
}

func LoadConfig

func LoadConfig() Config

type TestContext

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

func New

func New(config Config, t *testing.T) (*TestContext, error)

func (*TestContext) AssertExist

func (e *TestContext) AssertExist(path string)

func (*TestContext) Cat

func (e *TestContext) Cat(path string) string

func (*TestContext) Cd

func (e *TestContext) Cd(path string)

func (*TestContext) Close

func (e *TestContext) Close() error

func (*TestContext) Cwd

func (e *TestContext) Cwd() string

func (*TestContext) Debug

func (c *TestContext) Debug()

func (*TestContext) GetEnv

func (e *TestContext) GetEnv(name string) string

func (*TestContext) Ls

func (e *TestContext) Ls(path string) []string

func (*TestContext) Run

func (e *TestContext) Run(cmd string, optFns ...runOptionsFn) []string

func (*TestContext) Verbose

func (c *TestContext) Verbose()

func (*TestContext) Write

func (e *TestContext) Write(path, content string)

Jump to

Keyboard shortcuts

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