Explorar el Código

TestExecStopNotHanging: log output as string

When cmd failed, log its ouput as string instead of byte array to prevent test
log like: [49 53 ....] exit status 1

Signed-off-by: Daniel, Dao Quang Minh <dqminh89@gmail.com>
Daniel, Dao Quang Minh hace 10 años
padre
commit
d898372568
Se han modificado 1 ficheros con 2 adiciones y 1 borrados
  1. 2 1
      integration-cli/docker_cli_exec_test.go

+ 2 - 1
integration-cli/docker_cli_exec_test.go

@@ -321,7 +321,8 @@ func (s *DockerSuite) TestExecParseError(c *check.C) {
 }
 
 func (s *DockerSuite) TestExecStopNotHanging(c *check.C) {
-	if out, err := exec.Command(dockerBinary, "run", "-d", "--name", "testing", "busybox", "top").CombinedOutput(); err != nil {
+	runCmd := exec.Command(dockerBinary, "run", "-d", "--name", "testing", "busybox", "top")
+	if out, _, err := runCommandWithOutput(runCmd); err != nil {
 		c.Fatal(out, err)
 	}