From 3cd2ba28e48751f19809970b289c5bf96a5ec98c Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Wed, 30 Jan 2019 14:46:24 -0600 Subject: [PATCH] fix tests --- command/agent/job_endpoint_test.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/command/agent/job_endpoint_test.go b/command/agent/job_endpoint_test.go index 87ef38fd8..acd103c4c 100644 --- a/command/agent/job_endpoint_test.go +++ b/command/agent/job_endpoint_test.go @@ -1216,7 +1216,7 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { LTarget: "a", RTarget: "b", Operand: "c", - Weight: 50, + Weight: helper.Int8ToPtr(50), }, }, Update: &api.UpdateStrategy{ @@ -1232,7 +1232,7 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { Spreads: []*api.Spread{ { Attribute: "${meta.rack}", - Weight: helper.IntToPtr(100), + Weight: helper.Int8ToPtr(100), SpreadTarget: []*api.SpreadTarget{ { Value: "r1", @@ -1273,7 +1273,7 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { LTarget: "x", RTarget: "y", Operand: "z", - Weight: 100, + Weight: helper.Int8ToPtr(100), }, }, RestartPolicy: &api.RestartPolicy{ @@ -1299,7 +1299,7 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { Spreads: []*api.Spread{ { Attribute: "${node.datacenter}", - Weight: helper.IntToPtr(100), + Weight: helper.Int8ToPtr(100), SpreadTarget: []*api.SpreadTarget{ { Value: "dc1", @@ -1348,7 +1348,7 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { LTarget: "a", RTarget: "b", Operand: "c", - Weight: 50, + Weight: helper.Int8ToPtr(50), }, }, @@ -1432,7 +1432,7 @@ func TestJobs_ApiJobToStructsJob(t *testing.T) { LTarget: "a", RTarget: "b", Operand: "c", - Weight: 50, + Weight: helper.Int8ToPtr(50), }, }, },