Skip to content

Commit

Permalink
Merge pull request kubernetes#17944 from prezha/fix-TestRunningBinary…
Browse files Browse the repository at this point in the history
…Upgrade

bump legacyVersion to v1.26.0 from 2022-06-23
  • Loading branch information
prezha authored Jan 13, 2024
2 parents f9cd706 + 5d3de2a commit 838ea0c
Showing 1 changed file with 8 additions and 21 deletions.
29 changes: 8 additions & 21 deletions test/integration/version_upgrade_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,12 @@ import (
)

func installRelease(version string) (f *os.File, err error) {
tf, err := os.CreateTemp("", fmt.Sprintf("minikube-%s.*.exe", version))
ext := ""
if runtime.GOOS == "windows" {
ext = ".exe"
}

tf, err := os.CreateTemp("", fmt.Sprintf("minikube-%s.*%s", version, ext))
if err != nil {
return tf, err
}
Expand All @@ -59,27 +64,9 @@ func installRelease(version string) (f *os.File, err error) {

func legacyVersion() string {
// Should be a version from the last 6 months
version := "v1.6.2"
if KicDriver() {
if arm64Platform() {
// arm64 KIC driver is supported starting from v1.17.0
version = "v1.17.0"
} else {
// v1.8.0 would be selected, but: https://github.com/kubernetes/minikube/issues/8740
version = "v1.9.0"
}
}
if NoneDriver() {
// oldest version where none driver doesn't have to be run as root
version = "v1.16.0"
}
// the version containerd in ISO was upgraded to 1.4.2
// we need it to use runc.v2 plugin
// note: Test*BinaryUpgrade require minikube v1.22+ to satisfy newer containerd config structure
// note: TestMissingContainerUpgrade requires minikube v1.26.0+ where we copy over initial containerd config in kicbase via deploy/kicbase/Dockerfile
if ContainerRuntime() == "containerd" {
version = "v1.26.0"
}
version := "v1.26.0" // 2022-06-23
return version
}

Expand All @@ -90,7 +77,7 @@ func legacyStartArgs() []string {

// TestRunningBinaryUpgrade upgrades a running legacy cluster to minikube at HEAD
func TestRunningBinaryUpgrade(t *testing.T) {
// not supported till v1.10, and passing new images to old releases isn't supported anyways
// passing new images to old releases isn't supported anyways
if TestingKicBaseImage() {
t.Skipf("Skipping, test does not make sense with --base-image")
}
Expand Down

0 comments on commit 838ea0c

Please sign in to comment.