From 05d088f82dbf0fbfae8030bf62ca28e5ffac8c78 Mon Sep 17 00:00:00 2001 From: ecrupper Date: Wed, 1 Nov 2023 13:15:17 -0500 Subject: [PATCH] fix integration test --- database/integration_test.go | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/database/integration_test.go b/database/integration_test.go index 0cc6b1659..5dfb576a1 100644 --- a/database/integration_test.go +++ b/database/integration_test.go @@ -2314,6 +2314,12 @@ func newResources() *Resources { userTwo.SetActive(true) userTwo.SetAdmin(false) + _bPartialOne := new(library.Build) + _bPartialOne.SetID(1) + + _bPartialTwo := new(library.Build) + _bPartialTwo.SetID(2) + workerOne := new(api.Worker) workerOne.SetID(1) workerOne.SetHostname("worker-1.example.com") @@ -2322,7 +2328,7 @@ func newResources() *Resources { workerOne.SetActive(true) workerOne.SetStatus("available") workerOne.SetLastStatusUpdateAt(time.Now().UTC().Unix()) - workerOne.SetRunningBuilds([]*library.Build{buildOne}) + workerOne.SetRunningBuilds([]*library.Build{_bPartialOne}) workerOne.SetLastBuildStartedAt(time.Now().UTC().Unix()) workerOne.SetLastBuildFinishedAt(time.Now().UTC().Unix()) workerOne.SetLastCheckedIn(time.Now().UTC().Unix()) @@ -2336,7 +2342,7 @@ func newResources() *Resources { workerTwo.SetActive(true) workerTwo.SetStatus("available") workerTwo.SetLastStatusUpdateAt(time.Now().UTC().Unix()) - workerTwo.SetRunningBuilds([]*library.Build{buildTwo}) + workerTwo.SetRunningBuilds([]*library.Build{_bPartialTwo}) workerTwo.SetLastBuildStartedAt(time.Now().UTC().Unix()) workerTwo.SetLastBuildFinishedAt(time.Now().UTC().Unix()) workerTwo.SetLastCheckedIn(time.Now().UTC().Unix())