package cli
import "github.com/docker/cli/components/engine/integration-cli/cli"
Index ¶
- func Args(args ...string) icmd.Cmd
- func Build(name string) icmd.Cmd
- func BuildCmd(t testingT, name string, cmdOperators ...CmdOperator) *icmd.Result
- func Daemon(d *daemon.Daemon) func(*icmd.Cmd) func()
- func Docker(cmd icmd.Cmd, cmdOperators ...CmdOperator) *icmd.Result
- func DockerCmd(t testingT, args ...string) *icmd.Result
- func Format(format string) func(*icmd.Cmd) func()
- func InDir(path string) func(*icmd.Cmd) func()
- func Inspect(name string) icmd.Cmd
- func InspectCmd(t testingT, name string, cmdOperators ...CmdOperator) *icmd.Result
- func SetTestEnvironment(env *environment.Execution)
- func WaitExited(t testingT, name string, timeout time.Duration, cmdOperators ...CmdOperator)
- func WaitForInspectResult(t testingT, name, expr, expected string, timeout time.Duration, cmdOperators ...CmdOperator)
- func WaitRestart(t testingT, name string, timeout time.Duration, cmdOperators ...CmdOperator)
- func WaitRun(t testingT, name string, cmdOperators ...CmdOperator)
- func WithEnvironmentVariables(envs ...string) func(cmd *icmd.Cmd) func()
- func WithFlags(flags ...string) func(*icmd.Cmd) func()
- func WithStdin(stdin io.Reader) func(*icmd.Cmd) func()
- func WithStdout(writer io.Writer) func(*icmd.Cmd) func()
- func WithTimeout(timeout time.Duration) func(cmd *icmd.Cmd) func()
- type CmdOperator
Functions ¶
func Args ¶
Args build an icmd.Cmd struct from the specified arguments
func Build ¶
Build executes the specified docker build command
func BuildCmd ¶
func BuildCmd(t testingT, name string, cmdOperators ...CmdOperator) *icmd.Result
BuildCmd executes the specified docker build command and expect a success
func Daemon ¶
Daemon points to the specified daemon
func Docker ¶
func Docker(cmd icmd.Cmd, cmdOperators ...CmdOperator) *icmd.Result
Docker executes the specified docker command
func DockerCmd ¶
DockerCmd executes the specified docker command and expect a success
func Format ¶
Format sets the specified format with --format flag
func InDir ¶
InDir sets the folder in which the command should be executed
func Inspect ¶
Inspect executes the specified docker inspect command
func InspectCmd ¶
func InspectCmd(t testingT, name string, cmdOperators ...CmdOperator) *icmd.Result
InspectCmd executes the specified docker inspect command and expect a success
func SetTestEnvironment ¶
func SetTestEnvironment(env *environment.Execution)
SetTestEnvironment sets a static test environment TODO: decouple this package from environment
func WaitExited ¶
func WaitExited(t testingT, name string, timeout time.Duration, cmdOperators ...CmdOperator)
WaitExited will wait for the specified container to state exit, subject to a maximum time limit in seconds supplied by the caller
func WaitForInspectResult ¶
func WaitForInspectResult(t testingT, name, expr, expected string, timeout time.Duration, cmdOperators ...CmdOperator)
WaitForInspectResult waits for the specified expression to be equals to the specified expected string in the given time.
func WaitRestart ¶
func WaitRestart(t testingT, name string, timeout time.Duration, cmdOperators ...CmdOperator)
WaitRestart will wait for the specified container to restart once
func WaitRun ¶
func WaitRun(t testingT, name string, cmdOperators ...CmdOperator)
WaitRun will wait for the specified container to be running, maximum 5 seconds.
func WithEnvironmentVariables ¶
WithEnvironmentVariables sets the specified environment variables for the command to run
func WithFlags ¶
WithFlags sets the specified flags for the command to run
func WithStdin ¶
WithStdin sets the standard input reader for the command
func WithStdout ¶
WithStdout sets the standard output writer of the command
func WithTimeout ¶
WithTimeout sets the timeout for the command to run
Types ¶
type CmdOperator ¶
CmdOperator defines functions that can modify a command
Source Files ¶
Directories ¶
- Version
- v17.12.0-ce-rc2+incompatible
- Published
- Dec 12, 2017
- Platform
- darwin/amd64
- Imports
- 8 packages
- Last checked
- 23 seconds ago –
Tools for package owners.