From c0a5ec75c5a8f2d3ccb2f0c1a90f30bb20cdd60b Mon Sep 17 00:00:00 2001 From: Michael Crosby Date: Mon, 1 Sep 2014 17:09:52 -0700 Subject: [PATCH] Add more error info to TestDockerRunEchoStdoutWithMemoryLimit This test fails on my CI server often so we need more info when it does happen with this test. Signed-off-by: Michael Crosby --- integration-cli/docker_cli_run_test.go | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/integration-cli/docker_cli_run_test.go b/integration-cli/docker_cli_run_test.go index 81198ce213..00bbb2b2ca 100644 --- a/integration-cli/docker_cli_run_test.go +++ b/integration-cli/docker_cli_run_test.go @@ -41,8 +41,10 @@ func TestDockerRunEchoStdoutWithMemoryLimit(t *testing.T) { out, _, _, err := runCommandWithStdoutStderr(runCmd) errorOut(err, t, out) - if out != "test\n" { - t.Errorf("container should've printed 'test'") + out = strings.Trim(out, "\r\n") + + if expected := "test"; out != expected { + t.Errorf("container should've printed %q but printed %q", expected, out) }