Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

skip taint tests for 1.5-1.6 skew tests #43002

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
10 changes: 10 additions & 0 deletions test/e2e/framework/util.go
Expand Up @@ -1657,6 +1657,16 @@ func SkipUnlessKubectlVersionGTE(v semver.Version) {
}
}

func SkipUnlessKubectlVersionLTE(v semver.Version) {
gte, err := KubectlVersionGTE(v)
if err != nil {
Failf("Failed to get kubectl version: %v", err)
}
if gte {
Skipf("Not supported for kubectl versions after %q", v)
}
}

// KubectlVersionGTE returns true if the kubectl version is greater than or
// equal to v.
func KubectlVersionGTE(v semver.Version) (bool, error) {
Expand Down
2 changes: 2 additions & 0 deletions test/e2e/kubectl.go
Expand Up @@ -1333,6 +1333,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {

framework.KubeDescribe("Kubectl taint", func() {
It("should update the taint on a node", func() {
framework.SkipUnlessKubectlVersionLTE(version.MustParse("v1.6.0-alpha.3"))
testTaint := api.Taint{
Key: fmt.Sprintf("kubernetes.io/e2e-taint-key-001-%s", string(uuid.NewUUID())),
Value: "testing-taint-value",
Expand Down Expand Up @@ -1364,6 +1365,7 @@ var _ = framework.KubeDescribe("Kubectl client", func() {
})

It("should remove all the taints with the same key off a node", func() {
framework.SkipUnlessKubectlVersionLTE(version.MustParse("v1.6.0-alpha.3"))
testTaint := api.Taint{
Key: fmt.Sprintf("kubernetes.io/e2e-taint-key-002-%s", string(uuid.NewUUID())),
Value: "testing-taint-value",
Expand Down