mirror of
https://github.com/moby/moby.git
synced 2025-12-10 21:42:47 +03:00
Convert a legacy integration test to a clean v2 CLI integration test.
Docker-DCO-1.1-Signed-off-by: Solomon Hykes <solomon@docker.com> (github: shykes)
This commit is contained in:
@@ -4,6 +4,7 @@ import (
|
||||
"fmt"
|
||||
"os/exec"
|
||||
"strings"
|
||||
"testing"
|
||||
)
|
||||
|
||||
func deleteContainer(container string) error {
|
||||
@@ -54,3 +55,9 @@ func deleteImages(images string) error {
|
||||
|
||||
return err
|
||||
}
|
||||
|
||||
func cmd(t *testing.T, args ...string) (string, int, error) {
|
||||
out, status, err := runCommandWithOutput(exec.Command(dockerBinary, args...))
|
||||
errorOut(err, t, fmt.Sprintf("'%s' failed with errors: %v (%v)", strings.Join(args, " "), err, out))
|
||||
return out, status, err
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user