tests passing

Signed-off-by: Austin Abro <AustinAbro321@gmail.com>
pull/13604/head
Austin Abro 7 months ago
parent 0314135290
commit cc83b7c2e6
No known key found for this signature in database
GPG Key ID: 92EB5159E403F9D6

@ -242,11 +242,6 @@ func TestStatusWait(t *testing.T) {
expectErrs []error expectErrs []error
waitForJobs bool waitForJobs bool
}{ }{
{
name: "Job is complete",
objManifests: []string{jobCompleteManifest},
expectErrs: nil,
},
{ {
name: "Job is not complete", name: "Job is not complete",
objManifests: []string{jobNoStatusManifest}, objManifests: []string{jobNoStatusManifest},
@ -254,7 +249,7 @@ func TestStatusWait(t *testing.T) {
waitForJobs: true, waitForJobs: true,
}, },
{ {
name: "Job is not ready but we pass wait anyway", name: "Job is ready but not complete",
objManifests: []string{jobReadyManifest}, objManifests: []string{jobReadyManifest},
expectErrs: nil, expectErrs: nil,
waitForJobs: false, waitForJobs: false,
@ -310,12 +305,7 @@ func TestStatusWait(t *testing.T) {
resourceList = append(resourceList, list...) resourceList = append(resourceList, list...)
} }
var err error err := statusWaiter.Wait(resourceList, time.Second*3)
if tt.waitForJobs {
err = statusWaiter.WaitWithJobs(resourceList, time.Second*3)
} else {
err = statusWaiter.Wait(resourceList, time.Second*3)
}
if tt.expectErrs != nil { if tt.expectErrs != nil {
assert.EqualError(t, err, errors.Join(tt.expectErrs...).Error()) assert.EqualError(t, err, errors.Join(tt.expectErrs...).Error())
return return

Loading…
Cancel
Save