Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 2 additions & 6 deletions internal/client/job_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,17 +43,13 @@ func Test_setupLocalJobSystem(t *testing.T) {
WithClient(singleprocess.TestServer(t)),
WithUseLocalRunner(requestLocal),
)
defer c.Close()

// We don't need to upsert the project - it shouldn't need to make any API calls to
// choose a locality if we set it explicitly on the client.

isLocal, newCtx, err := c.setupLocalJobSystem(ctx)
require.Nil(err)
require.Equal(requestLocal, isLocal)

// Check that running setupLocalJobSystem had the right side effects
validateLocalSetupSideEffects(newCtx, c, requestLocal)
require.NoError(c.Close())
}
})

Expand All @@ -63,7 +59,7 @@ func Test_setupLocalJobSystem(t *testing.T) {
c := TestProject(t,
WithClient(singleprocess.TestServer(t)),
)
defer c.Close()
t.Cleanup(func() { require.NoError(c.Close()) })

project := &pb.Project{
Name: c.project.Project,
Expand Down
Loading