Skip to content

Commit

Permalink
cgroupv1: kubeadm: do not run tests for version >= 4179
Browse files Browse the repository at this point in the history
  • Loading branch information
ader1990 committed Dec 11, 2024
1 parent 5fe8bbd commit 7463baf
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 6 deletions.
14 changes: 9 additions & 5 deletions kola/tests/kubeadm/kubeadm.go
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ import (
"bytes"
"encoding/base64"
"fmt"
"math"
"strings"
"text/template"
"time"
Expand Down Expand Up @@ -146,10 +147,12 @@ func init() {
testParams["Release"] = version

cgroupSuffix := ""
var major int64 = 0
var majorMinVersion int64 = 0
var majorEndVersion int64 = math.MaxInt64
if testParams["cgroupv1"].(bool) {
cgroupSuffix = ".cgroupv1"
major = 3140
majorMinVersion = 3140
majorEndVersion = 4179
}

if CNI == "flannel" {
Expand All @@ -160,8 +163,8 @@ func init() {
mmv := (int64)(mmvi.(int))
// Careful, so we don't lower
// the min version too much.
if mmv > major {
major = mmv
if mmv > majorMinVersion {
majorMinVersion = mmv
}
}

Expand All @@ -174,7 +177,8 @@ func init() {
Run: func(c cluster.TestCluster) {
kubeadmBaseTest(c, testParams)
},
MinVersion: semver.Version{Major: major},
MinVersion: semver.Version{Major: majorMinVersion},
EndVersion: semver.Version{Major: majorEndVersion},
Flags: flags,
})
}
Expand Down
2 changes: 1 addition & 1 deletion kola/tests/misc/cgroup1.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ func init() {
},
Distros: []string{"cl"},
MinVersion: semver.Version{Major: 3033},
EndVersion: semver.Version{Major: 4152},
EndVersion: semver.Version{Major: 4179},
// This test is normally not related to the cloud environment
Platforms: []string{"qemu", "qemu-unpriv"},
})
Expand Down

0 comments on commit 7463baf

Please sign in to comment.