Skip to content

Commit 8f5177b

Browse files
authored
Merge pull request #5495 from jsturtevant/use-correct-version-on-tests
🌱 Use kubernetes version instead of Upgrade to/from
2 parents 59f33c5 + 954b77e commit 8f5177b

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

test/e2e/machine_pool.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,8 @@ func MachinePoolSpec(ctx context.Context, inputGetter func() MachinePoolInput) {
6565
Expect(input.ClusterctlConfigPath).To(BeAnExistingFile(), "Invalid argument. input.ClusterctlConfigPath must be an existing file when calling %s spec", specName)
6666
Expect(input.BootstrapClusterProxy).ToNot(BeNil(), "Invalid argument. input.BootstrapClusterProxy can't be nil when calling %s spec", specName)
6767
Expect(os.MkdirAll(input.ArtifactFolder, 0755)).To(Succeed(), "Invalid argument. input.ArtifactFolder can't be created for %s spec", specName)
68-
Expect(input.E2EConfig.Variables).To(HaveKey(KubernetesVersionUpgradeTo))
69-
Expect(input.E2EConfig.Variables).To(HaveKey(KubernetesVersionUpgradeFrom))
68+
Expect(input.E2EConfig.Variables).To(HaveKey(KubernetesVersion))
69+
Expect(input.E2EConfig.Variables).To(HaveValidVersion(input.E2EConfig.GetVariable(KubernetesVersion)))
7070

7171
// Setup a Namespace where to host objects for this spec and create a watcher for the namespace events.
7272
namespace, cancelWatches = setupSpecNamespace(ctx, specName, input.BootstrapClusterProxy, input.ArtifactFolder)
@@ -86,7 +86,7 @@ func MachinePoolSpec(ctx context.Context, inputGetter func() MachinePoolInput) {
8686
Flavor: pointer.StringDeref(input.Flavor, "machine-pool"),
8787
Namespace: namespace.Name,
8888
ClusterName: fmt.Sprintf("%s-%s", specName, util.RandomString(6)),
89-
KubernetesVersion: input.E2EConfig.GetVariable(KubernetesVersionUpgradeFrom),
89+
KubernetesVersion: input.E2EConfig.GetVariable(KubernetesVersion),
9090
ControlPlaneMachineCount: pointer.Int64Ptr(1),
9191
WorkerMachineCount: pointer.Int64Ptr(int64(workerMachineCount)),
9292
},

test/e2e/md_rollout.go

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,6 @@ func MachineDeploymentRolloutSpec(ctx context.Context, inputGetter func() Machin
6262
Expect(os.MkdirAll(input.ArtifactFolder, 0750)).To(Succeed(), "Invalid argument. input.ArtifactFolder can't be created for %s spec", specName)
6363
Expect(input.E2EConfig.Variables).To(HaveKey(KubernetesVersion))
6464
Expect(input.E2EConfig.Variables).To(HaveValidVersion(input.E2EConfig.GetVariable(KubernetesVersion)))
65-
Expect(input.E2EConfig.Variables).To(HaveKey(KubernetesVersionUpgradeFrom))
66-
Expect(input.E2EConfig.Variables).To(HaveValidVersion(input.E2EConfig.GetVariable(KubernetesVersionUpgradeFrom)))
6765

6866
// Setup a Namespace where to host objects for this spec and create a watcher for the namespace events.
6967
namespace, cancelWatches = setupSpecNamespace(ctx, specName, input.BootstrapClusterProxy, input.ArtifactFolder)
@@ -82,7 +80,7 @@ func MachineDeploymentRolloutSpec(ctx context.Context, inputGetter func() Machin
8280
Flavor: input.Flavor,
8381
Namespace: namespace.Name,
8482
ClusterName: fmt.Sprintf("%s-%s", specName, util.RandomString(6)),
85-
KubernetesVersion: input.E2EConfig.GetVariable(KubernetesVersionUpgradeFrom),
83+
KubernetesVersion: input.E2EConfig.GetVariable(KubernetesVersion),
8684
ControlPlaneMachineCount: pointer.Int64Ptr(1),
8785
WorkerMachineCount: pointer.Int64Ptr(1),
8886
},

0 commit comments

Comments
 (0)