@@ -148,6 +148,38 @@ var _ = Describe("Workload cluster creation", func() {
148148 ControlPlane : result .ControlPlane ,
149149 }, e2eConfig .GetIntervals (specName , "wait-control-plane" )... )
150150
151+ By ("Upgrading control plane and worker machines" )
152+ ApplyClusterTemplateAndWait (ctx , ApplyClusterTemplateAndWaitInput {
153+ ClusterProxy : bootstrapClusterProxy ,
154+ ConfigCluster : clusterctl.ConfigClusterInput {
155+ LogFolder : clusterctlLogFolder ,
156+ ClusterctlConfigPath : clusterctlConfigPath ,
157+ KubeconfigPath : bootstrapClusterProxy .GetKubeconfigPath (),
158+ InfrastructureProvider : "docker" ,
159+ Flavor : "docker" ,
160+ Namespace : namespace .Name ,
161+ ClusterName : clusterName ,
162+ KubernetesVersion : e2eConfig .GetVariable (KubernetesVersionUpgradeTo ),
163+ ControlPlaneMachineCount : pointer .Int64Ptr (3 ),
164+ WorkerMachineCount : pointer .Int64Ptr (3 ),
165+ },
166+ WaitForClusterIntervals : e2eConfig .GetIntervals (specName , "wait-cluster" ),
167+ WaitForControlPlaneIntervals : e2eConfig .GetIntervals (specName , "wait-control-plane" ),
168+ WaitForMachineDeployments : e2eConfig .GetIntervals (specName , "wait-worker-nodes" ),
169+ }, result )
170+
171+ WaitForClusterToUpgrade (ctx , WaitForClusterToUpgradeInput {
172+ Lister : bootstrapClusterProxy .GetClient (),
173+ ControlPlane : result .ControlPlane ,
174+ MachineDeployments : result .MachineDeployments ,
175+ VersionAfterUpgrade : e2eConfig .GetVariable (KubernetesVersionUpgradeTo ),
176+ }, e2eConfig .GetIntervals (specName , "wait-control-plane" )... )
177+
178+ WaitForControlPlaneToBeReady (ctx , WaitForControlPlaneToBeReadyInput {
179+ Getter : bootstrapClusterProxy .GetClient (),
180+ ControlPlane : result .ControlPlane ,
181+ }, e2eConfig .GetIntervals (specName , "wait-control-plane" )... )
182+
151183 // TODO: this can be uncommented when control plane scaling down is working
152184
153185 // By("Scaling control plane nodes to 1")
0 commit comments