From c49a3e20c5214e12436c79d5cb2906cfb6bb9e57 Mon Sep 17 00:00:00 2001 From: Preetha Appan Date: Fri, 2 Nov 2018 16:06:25 -0500 Subject: [PATCH] Fix test setup --- scheduler/preemption_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/scheduler/preemption_test.go b/scheduler/preemption_test.go index cdca7153c..cf6f1ef26 100644 --- a/scheduler/preemption_test.go +++ b/scheduler/preemption_test.go @@ -318,7 +318,7 @@ func TestPreemption(t *testing.T) { }, }, { - desc: "preempt only from device that has allocation with used reserved port", + desc: "preempt only from device that has allocation with unused reserved port", currentAllocations: []*structs.Allocation{ createAlloc(allocIDs[0], highPrioJob, &structs.Resources{ CPU: 1200, @@ -333,7 +333,7 @@ func TestPreemption(t *testing.T) { }, }, }), - createAlloc(allocIDs[1], lowPrioJob, &structs.Resources{ + createAlloc(allocIDs[1], highPrioJob, &structs.Resources{ CPU: 200, MemoryMB: 256, DiskMB: 4 * 1024, @@ -405,7 +405,7 @@ func TestPreemption(t *testing.T) { }, }, preemptedAllocIDs: map[string]struct{}{ - allocIDs[1]: {}, + allocIDs[2]: {}, }, }, {