From 142369456d2469a06e3860bdfe13169a908a3707 Mon Sep 17 00:00:00 2001 From: Tianon Gravi Date: Tue, 20 Jan 2015 12:11:59 -0700 Subject: [PATCH] Update TestBuildWithTabs to allow for the "\t"-equivalent "\u0009" (for Go 1.3 support) This is literally the only failing test on Go 1.3.3: :tada: ``` --- FAIL: TestBuildWithTabs (0.43 seconds) docker_cli_build_test.go:4307: Missing tabs. Got:["/bin/sh","-c","echo\u0009one\u0009\u0009two"] Exp:["/bin/sh","-c","echo\tone\t\ttwo"] ``` Signed-off-by: Andrew "Tianon" Page --- integration-cli/docker_cli_build_test.go | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/integration-cli/docker_cli_build_test.go b/integration-cli/docker_cli_build_test.go index 4330115fca..479b9692da 100644 --- a/integration-cli/docker_cli_build_test.go +++ b/integration-cli/docker_cli_build_test.go @@ -4302,9 +4302,10 @@ func TestBuildWithTabs(t *testing.T) { if err != nil { t.Fatal(err) } - expected := `["/bin/sh","-c","echo\tone\t\ttwo"]` - if res != expected { - t.Fatalf("Missing tabs.\nGot:%s\nExp:%s", res, expected) + expected1 := `["/bin/sh","-c","echo\tone\t\ttwo"]` + expected2 := `["/bin/sh","-c","echo\u0009one\u0009\u0009two"]` // syntactically equivalent, and what Go 1.3 generates + if res != expected1 && res != expected2 { + t.Fatalf("Missing tabs.\nGot: %s\nExp: %s or %s", res, expected1, expected2) } logDone("build - with tabs") }