From 0d59f4305cbb1aaae1b0c6aab94c1e5a08b50bfb Mon Sep 17 00:00:00 2001 From: Kir Kolyshkin Date: Mon, 10 Sep 2018 16:26:40 -0700 Subject: [PATCH] TestStartReturnCorrectExitCode: show error Signed-off-by: Kir Kolyshkin --- integration-cli/docker_cli_start_test.go | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/integration-cli/docker_cli_start_test.go b/integration-cli/docker_cli_start_test.go index cbe917bf4f..303deddb28 100644 --- a/integration-cli/docker_cli_start_test.go +++ b/integration-cli/docker_cli_start_test.go @@ -190,10 +190,11 @@ func (s *DockerSuite) TestStartReturnCorrectExitCode(c *check.C) { dockerCmd(c, "create", "--restart=on-failure:2", "--name", "withRestart", "busybox", "sh", "-c", "exit 11") dockerCmd(c, "create", "--rm", "--name", "withRm", "busybox", "sh", "-c", "exit 12") - _, exitCode, err := dockerCmdWithError("start", "-a", "withRestart") + out, exitCode, err := dockerCmdWithError("start", "-a", "withRestart") c.Assert(err, checker.NotNil) - c.Assert(exitCode, checker.Equals, 11) - _, exitCode, err = dockerCmdWithError("start", "-a", "withRm") + c.Assert(exitCode, checker.Equals, 11, check.Commentf("out: %s", out)) + + out, exitCode, err = dockerCmdWithError("start", "-a", "withRm") c.Assert(err, checker.NotNil) - c.Assert(exitCode, checker.Equals, 12) + c.Assert(exitCode, checker.Equals, 12, check.Commentf("out: %s", out)) }