Skip to content

Commit 5b2cc5b

Browse files
authored
Merge pull request #1894 from Nordix/lentzi90/add-0.9-upgrade
🌱 E2E: Add clusterctl upgrade test for v0.9 -> main
2 parents d189b1b + ce11691 commit 5b2cc5b

File tree

2 files changed

+37
-0
lines changed

2 files changed

+37
-0
lines changed

test/e2e/data/e2e_conf.yaml

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -139,6 +139,20 @@ providers:
139139
new: "--v=4"
140140
- old: "--leader-elect"
141141
new: "--leader-elect=false\n - --sync-period=1m"
142+
- name: v0.9.0
143+
value: "https://github.com/kubernetes-sigs/cluster-api-provider-openstack/releases/download/v0.9.0/infrastructure-components.yaml"
144+
type: url
145+
contract: v1beta1
146+
files:
147+
- sourcePath: "../data/shared/v1beta1_provider/metadata.yaml"
148+
- sourcePath: "./infrastructure-openstack-no-artifact/cluster-template.yaml"
149+
replacements:
150+
- old: "imagePullPolicy: Always"
151+
new: "imagePullPolicy: IfNotPresent"
152+
- old: "--v=2"
153+
new: "--v=4"
154+
- old: "--leader-elect"
155+
new: "--leader-elect=false\n - --sync-period=1m"
142156
- name: v0.9.99
143157
value: ../../../config/default
144158
# This is the upcoming version.

test/e2e/suites/e2e/clusterctl_upgrade_test.go

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,3 +75,26 @@ var _ = Describe("When testing clusterctl upgrades (v0.8=>current) [clusterctl-u
7575
}
7676
})
7777
})
78+
79+
var _ = Describe("When testing clusterctl upgrades (v0.9=>current) [clusterctl-upgrade]", func() {
80+
ctx := context.TODO()
81+
shared.SetEnvVar("DOWNLOAD_E2E_IMAGE", "true", false)
82+
83+
capi_e2e.ClusterctlUpgradeSpec(ctx, func() capi_e2e.ClusterctlUpgradeSpecInput {
84+
return capi_e2e.ClusterctlUpgradeSpecInput{
85+
E2EConfig: e2eCtx.E2EConfig,
86+
ClusterctlConfigPath: e2eCtx.Environment.ClusterctlConfigPath,
87+
BootstrapClusterProxy: e2eCtx.Environment.BootstrapClusterProxy,
88+
ArtifactFolder: e2eCtx.Settings.ArtifactFolder,
89+
SkipCleanup: false,
90+
InitWithBinary: "https://github.com/kubernetes-sigs/cluster-api/releases/download/" + OldCAPIVersion + "/clusterctl-{OS}-{ARCH}",
91+
InitWithProvidersContract: "v1beta1",
92+
InitWithInfrastructureProviders: []string{"openstack:v0.9.0"},
93+
InitWithCoreProvider: "cluster-api:" + OldCAPIVersion,
94+
InitWithBootstrapProviders: []string{"kubeadm:" + OldCAPIVersion},
95+
InitWithControlPlaneProviders: []string{"kubeadm:" + OldCAPIVersion},
96+
MgmtFlavor: shared.FlavorDefault,
97+
WorkloadFlavor: shared.FlavorV1alpha7,
98+
}
99+
})
100+
})

0 commit comments

Comments
 (0)