Skip to content

Commit

Permalink
Merge pull request #569 from flatcar/ader1990/disable_cgroupv1_tests
Browse files Browse the repository at this point in the history
cgroupv1: do not run tests for version >= 4179
  • Loading branch information
ader1990 authored Dec 12, 2024
2 parents 28a2bfa + 7463baf commit 34b4d28
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 5 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
1 change: 1 addition & 0 deletions kola/tests/misc/cgroup1.go
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,7 @@ func init() {
},
Distros: []string{"cl"},
MinVersion: semver.Version{Major: 3033},
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 34b4d28

Please sign in to comment.