@@ -143,7 +143,8 @@ func TestMNISTPyTorchMCAD(t *testing.T) {
143
143
},
144
144
},
145
145
},
146
- GenericTemplate : Raw (test , job ),
146
+ GenericTemplate : Raw (test , job ),
147
+ CompletionStatus : "Complete" ,
147
148
},
148
149
},
149
150
},
@@ -159,13 +160,13 @@ func TestMNISTPyTorchMCAD(t *testing.T) {
159
160
Should (WithTransform (AppWrapperState , Equal (mcadv1beta1 .AppWrapperStateActive )))
160
161
161
162
test .T ().Logf ("Waiting for Job %s/%s to complete" , job .Namespace , job .Name )
162
- test .Eventually (Job (test , job . Namespace , job .Name ), TestTimeoutLong ).Should (
163
+ test .Eventually (AppWrapper (test , namespace , aw .Name ), TestTimeoutLong ).Should (
163
164
Or (
164
- WithTransform (ConditionStatus ( batchv1 . JobComplete ) , Equal (corev1 . ConditionTrue )),
165
- WithTransform (ConditionStatus ( batchv1 . JobFailed ) , Equal (corev1 . ConditionTrue )),
165
+ WithTransform (AppWrapperState , Equal (mcadv1beta1 . AppWrapperStateCompleted )),
166
+ WithTransform (AppWrapperState , Equal (mcadv1beta1 . AppWrapperStateFailed )),
166
167
))
167
168
168
169
// Assert the job has completed successfully
169
- test .Expect (GetJob (test , job . Namespace , job .Name )).
170
- To (WithTransform (ConditionStatus ( batchv1 . JobComplete ) , Equal (corev1 . ConditionTrue )))
170
+ test .Expect (GetAppWrapper (test , namespace , aw .Name )).
171
+ To (WithTransform (AppWrapperState , Equal (mcadv1beta1 . AppWrapperStateCompleted )))
171
172
}
0 commit comments