@@ -27,22 +27,15 @@ func runFailedPyTorchJobTest(t *testing.T, image string) {
2727 // Create a namespace
2828 namespace := test .NewTestNamespace ()
2929
30- // Create a ConfigMap with training dataset and configuration
31- configData := map [string ][]byte {
32- "config.json" : ReadFile (test , "config.json" ),
33- "twitter_complaints_small.json" : ReadFile (test , "twitter_complaints_small.json" ),
34- }
35- config := CreateConfigMap (test , namespace .Name , configData )
36-
3730 // Create training PyTorch job
38- tuningJob := createFailedPyTorchJob (test , namespace .Name , * config , image )
31+ tuningJob := createFailedPyTorchJob (test , namespace .Name , image )
3932
4033 // Make sure the PyTorch job is failed
41- test .Eventually (PyTorchJob (test , namespace .Name , tuningJob .Name ), TestTimeoutLong ).
34+ test .Eventually (PyTorchJob (test , namespace .Name , tuningJob .Name ), TestTimeoutDouble ).
4235 Should (WithTransform (PyTorchJobConditionFailed , Equal (corev1 .ConditionTrue )))
4336}
4437
45- func createFailedPyTorchJob (test Test , namespace string , config corev1. ConfigMap , baseImage string ) * kftov1.PyTorchJob {
38+ func createFailedPyTorchJob (test Test , namespace string , baseImage string ) * kftov1.PyTorchJob {
4639 tuningJob := & kftov1.PyTorchJob {
4740 TypeMeta : metav1.TypeMeta {
4841 APIVersion : corev1 .SchemeGroupVersion .String (),
@@ -80,18 +73,6 @@ func createFailedPyTorchJob(test Test, namespace string, config corev1.ConfigMap
8073 },
8174 },
8275 },
83- Volumes : []corev1.Volume {
84- {
85- Name : "config-volume" ,
86- VolumeSource : corev1.VolumeSource {
87- ConfigMap : & corev1.ConfigMapVolumeSource {
88- LocalObjectReference : corev1.LocalObjectReference {
89- Name : config .Name ,
90- },
91- },
92- },
93- },
94- },
9576 },
9677 },
9778 },
0 commit comments