From 85860dcb676ef8bb1b6cbfce8870bf4430611796 Mon Sep 17 00:00:00 2001 From: Michael Schurter Date: Mon, 26 Jun 2017 12:53:43 -0700 Subject: [PATCH] Fix test error formats --- command/agent/consul/unit_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/command/agent/consul/unit_test.go b/command/agent/consul/unit_test.go index 8a42cd5fb..ceec772b5 100644 --- a/command/agent/consul/unit_test.go +++ b/command/agent/consul/unit_test.go @@ -1040,7 +1040,7 @@ func TestConsul_DriverNetwork_AutoUse(t *testing.T) { // be the same as their order in the Task definition, // so check in a loop if expected := 2; len(v.Checks) != expected { - t.Errorf("expected %d checks but found %d", len(v.Checks)) + t.Errorf("expected %d checks but found %d", expected, len(v.Checks)) } for _, c := range v.Checks { // No name on AgentServiceChecks, use type @@ -1077,7 +1077,7 @@ func TestConsul_DriverNetwork_AutoUse(t *testing.T) { } case ctx.Task.Services[2].Name: // y + host mode if v.Port != yPort { - t.Errorf("expected service %s's port to be %d but found %s", + t.Errorf("expected service %s's port to be %d but found %d", v.Name, yPort, v.Port) } default: @@ -1151,7 +1151,7 @@ func TestConsul_DriverNetwork_NoAutoUse(t *testing.T) { } case ctx.Task.Services[2].Name: // y + host mode if v.Port != yPort { - t.Errorf("expected service %s's port to be %d but found %s", + t.Errorf("expected service %s's port to be %d but found %d", v.Name, yPort, v.Port) } default: