@@ -104,7 +104,7 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
104104 name : "No-op" ,
105105 localExisting : []runtime.Object {
106106 testClusterDeployment ([]hivev1.MachinePool {
107- testMachinePool ("worker" , 3 , testName + "-worker" , []string {}),
107+ testMachinePool ("worker" , 3 , []string {}),
108108 }),
109109 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
110110 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -130,7 +130,7 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
130130 name : "Update machine set replicas" ,
131131 localExisting : []runtime.Object {
132132 testClusterDeployment ([]hivev1.MachinePool {
133- testMachinePool ("worker" , 3 , testName + "-worker" , []string {}),
133+ testMachinePool ("worker" , 3 , []string {}),
134134 }),
135135 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
136136 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -156,7 +156,7 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
156156 name : "Create missing machine set" ,
157157 localExisting : []runtime.Object {
158158 testClusterDeployment ([]hivev1.MachinePool {
159- testMachinePool ("worker" , 3 , testName + "-worker" , []string {"us-east-1a" , "us-east-1b" , "us-east-1c" }),
159+ testMachinePool ("worker" , 3 , []string {"us-east-1a" , "us-east-1b" , "us-east-1c" }),
160160 }),
161161 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
162162 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -181,7 +181,7 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
181181 name : "Delete extra machine set" ,
182182 localExisting : []runtime.Object {
183183 testClusterDeployment ([]hivev1.MachinePool {
184- testMachinePool ("worker" , 3 , testName + "-worker" , []string {}),
184+ testMachinePool ("worker" , 3 , []string {}),
185185 }),
186186 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
187187 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -208,8 +208,8 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
208208 name : "Multiple machineset noop" ,
209209 localExisting : []runtime.Object {
210210 testClusterDeployment ([]hivev1.MachinePool {
211- testMachinePool ("alpha" , 3 , testName + "-worker" , []string {"us-east-1a" }),
212- testMachinePool ("beta" , 3 , testName + "-worker" , []string {"us-east-1b" }),
211+ testMachinePool ("alpha" , 3 , []string {"us-east-1a" }),
212+ testMachinePool ("beta" , 3 , []string {"us-east-1b" }),
213213 }),
214214 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
215215 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -233,8 +233,8 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
233233 name : "Update multiple machineset replicas" ,
234234 localExisting : []runtime.Object {
235235 testClusterDeployment ([]hivev1.MachinePool {
236- testMachinePool ("alpha" , 3 , testName + "-worker" , []string {"us-east-1a" }),
237- testMachinePool ("beta" , 3 , testName + "-worker" , []string {"us-east-1b" }),
236+ testMachinePool ("alpha" , 3 , []string {"us-east-1a" }),
237+ testMachinePool ("beta" , 3 , []string {"us-east-1b" }),
238238 }),
239239 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
240240 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -258,8 +258,8 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
258258 name : "Create additional machinepool machinesets" ,
259259 localExisting : []runtime.Object {
260260 testClusterDeployment ([]hivev1.MachinePool {
261- testMachinePool ("alpha" , 3 , testName + "-worker" , []string {}),
262- testMachinePool ("beta" , 3 , testName + "-worker" , []string {}),
261+ testMachinePool ("alpha" , 3 , []string {}),
262+ testMachinePool ("beta" , 3 , []string {}),
263263 }),
264264 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
265265 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -288,7 +288,7 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
288288 name : "Delete additional machinepool machinesets" ,
289289 localExisting : []runtime.Object {
290290 testClusterDeployment ([]hivev1.MachinePool {
291- testMachinePool ("alpha" , 3 , testName + "-worker" , []string {}),
291+ testMachinePool ("alpha" , 3 , []string {}),
292292 }),
293293 testSecret (adminKubeconfigSecret , adminKubeconfigSecretKey , testName ),
294294 testSecret (adminPasswordSecret , adminPasswordSecretKey , testName ),
@@ -391,7 +391,7 @@ func TestRemoteMachineSetReconcile(t *testing.T) {
391391 }
392392}
393393
394- func testMachinePool (name string , replicas int , iamRoleName string , zones []string ) hivev1.MachinePool {
394+ func testMachinePool (name string , replicas int , zones []string ) hivev1.MachinePool {
395395 mpReplicas := int64 (replicas )
396396
397397 testMachinePool := hivev1.MachinePool {
@@ -400,7 +400,6 @@ func testMachinePool(name string, replicas int, iamRoleName string, zones []stri
400400 Platform : hivev1.MachinePoolPlatform {
401401 AWS : & hivev1.AWSMachinePoolPlatform {
402402 InstanceType : "m4.large" ,
403- IAMRoleName : iamRoleName ,
404403 },
405404 },
406405 }
0 commit comments