@@ -38,7 +38,7 @@ func TestMNISTRayJobMCADRayCluster(t *testing.T) {
3838 // Create a namespace
3939 namespace := test .NewTestNamespace ()
4040
41- // Job script
41+ // MNIST training script
4242 mnist , err := scripts .ReadFile ("mnist.py" )
4343 test .Expect (err ).NotTo (HaveOccurred ())
4444
@@ -66,39 +66,21 @@ func TestMNISTRayJobMCADRayCluster(t *testing.T) {
6666 Kind : "RayCluster" ,
6767 },
6868 ObjectMeta : metav1.ObjectMeta {
69- Name : "raycluster-autoscaler " ,
69+ Name : "raycluster" ,
7070 Namespace : namespace .Name ,
7171 },
7272 Spec : rayv1alpha1.RayClusterSpec {
73- RayVersion : "2.0.0" ,
74- EnableInTreeAutoscaling : Ptr (true ),
75- AutoscalerOptions : & rayv1alpha1.AutoscalerOptions {
76- UpscalingMode : Ptr [rayv1alpha1.UpscalingMode ]("Default" ),
77- IdleTimeoutSeconds : Ptr (int32 (60 )),
78- ImagePullPolicy : Ptr (corev1 .PullAlways ),
79- Resources : & corev1.ResourceRequirements {
80- Requests : corev1.ResourceList {
81- corev1 .ResourceCPU : resource .MustParse ("250m" ),
82- corev1 .ResourceMemory : resource .MustParse ("512Mi" ),
83- },
84- Limits : corev1.ResourceList {
85- corev1 .ResourceCPU : resource .MustParse ("250m" ),
86- corev1 .ResourceMemory : resource .MustParse ("512Mi" ),
87- },
88- },
89- },
73+ RayVersion : "2.0.0" ,
9074 HeadGroupSpec : rayv1alpha1.HeadGroupSpec {
9175 RayStartParams : map [string ]string {
9276 "dashboard-host" : "0.0.0.0" ,
93- "block" : "true" ,
9477 },
9578 Template : corev1.PodTemplateSpec {
9679 Spec : corev1.PodSpec {
9780 Containers : []corev1.Container {
9881 {
99- Name : "ray-head" ,
100- Image : "rayproject/ray:2.0.0" ,
101- ImagePullPolicy : corev1 .PullAlways ,
82+ Name : "ray-head" ,
83+ Image : "rayproject/ray:2.0.0" ,
10284 Ports : []corev1.ContainerPort {
10385 {
10486 ContainerPort : 6379 ,
@@ -155,13 +137,11 @@ func TestMNISTRayJobMCADRayCluster(t *testing.T) {
155137 },
156138 WorkerGroupSpecs : []rayv1alpha1.WorkerGroupSpec {
157139 {
158- Replicas : Ptr (int32 (1 )),
159- MinReplicas : Ptr (int32 (1 )),
160- MaxReplicas : Ptr (int32 (3 )),
161- GroupName : "small-group" ,
162- RayStartParams : map [string ]string {
163- "block" : "true" ,
164- },
140+ Replicas : Ptr (int32 (1 )),
141+ MinReplicas : Ptr (int32 (1 )),
142+ MaxReplicas : Ptr (int32 (2 )),
143+ GroupName : "small-group" ,
144+ RayStartParams : map [string ]string {},
165145 Template : corev1.PodTemplateSpec {
166146 Spec : corev1.PodSpec {
167147 InitContainers : []corev1.Container {
@@ -173,9 +153,8 @@ func TestMNISTRayJobMCADRayCluster(t *testing.T) {
173153 },
174154 Containers : []corev1.Container {
175155 {
176- Name : "machine-learning" ,
177- Image : "rayproject/ray:2.0.0" ,
178- ImagePullPolicy : corev1 .PullAlways ,
156+ Name : "ray-worker" ,
157+ Image : "rayproject/ray:2.0.0" ,
179158 Lifecycle : & corev1.Lifecycle {
180159 PreStop : & corev1.LifecycleHandler {
181160 Exec : & corev1.ExecAction {
0 commit comments