File tree Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Expand file tree Collapse file tree 1 file changed +12
-0
lines changed Original file line number Diff line number Diff line change @@ -9,12 +9,24 @@ import (
99 "testing"
1010 "time"
1111
12+ "github.com/Masterminds/semver"
1213 "github.com/hashicorp/go-hclog"
1314 "github.com/hashicorp/terraform-provider-kubernetes/manifest/provider"
1415 tfstatehelper "github.com/hashicorp/terraform-provider-kubernetes/manifest/test/helper/state"
1516)
1617
1718func TestKubernetesManifest_NonStructuredCustomResource (t * testing.T ) {
19+ cv , err := semver .NewVersion (k8shelper .ClusterVersion ().String ())
20+ if err != nil {
21+ t .Skip ("cannot determine cluster version" )
22+ }
23+ mv , err := semver .NewConstraint (">= 1.22.0" )
24+ if err != nil {
25+ t .Skip ("cannot establish cluster version constraint" )
26+ }
27+ if mv .Check (cv ) {
28+ t .Skip ("only applicable to cluster versions < 1.22" )
29+ }
1830 kind := randName ()
1931 plural := strings .ToLower (kind ) + "s"
2032 group := "k8s.terraform.io"
You can’t perform that action at this time.
0 commit comments