We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 967fa2f commit 985cc70Copy full SHA for 985cc70
test/helpers/envtest.go
@@ -56,6 +56,14 @@ func newTestEnvironment() *TestEnvironment {
56
_, filename, _, _ := goruntime.Caller(0) //nolint
57
root := path.Join(path.Dir(filename), "..", "..")
58
59
+ // Every time a CRD are created, ResourceVersion is set and this will prevent creation of
60
+ // subsequent test environments; so we are enforcing empty ResourceVersion to make it is possible
61
+ // to create more TestEnvironments.
62
+ external.TestGenericBootstrapCRD.SetResourceVersion("")
63
+ external.TestGenericBootstrapTemplateCRD.SetResourceVersion("")
64
+ external.TestGenericInfrastructureCRD.SetResourceVersion("")
65
+ external.TestGenericInfrastructureTemplateCRD.SetResourceVersion("")
66
+
67
return &TestEnvironment{
68
Environment: &envtest.Environment{
69
ErrorIfCRDPathMissing: true,
0 commit comments