Skip to content

Commit aac1d58

Browse files
authored
Don't export ValidationSplitWebhook test (#10394)
1 parent 0f99be1 commit aac1d58

File tree

3 files changed

+23
-2
lines changed

3 files changed

+23
-2
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
changelog:
2+
- type: NON_USER_FACING
3+
issueLink: https://github.com/solo-io/solo-projects/issues/7256
4+
resolvesIssue: false
5+
description: >-
6+
Create a new SuiteRunner for the ValidationTests which does not include the split validation test, which
7+
fails when imported by other projects. https://github.com/k8sgateway/k8sgateway/issues/10374 created to
8+
track a fix that will allow tests that update Helm values to be exported.

test/kubernetes/e2e/tests/validation_strict_test.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -50,5 +50,5 @@ func TestValidationStrict(t *testing.T) {
5050
// Install Gloo Gateway with correct validation settings
5151
testInstallation.InstallGlooGatewayWithTestHelper(ctx, testHelper, 5*time.Minute)
5252

53-
ValidationStrictSuiteRunner().Run(ctx, t, testInstallation)
53+
ValidationStrictSuiteRunnerAll().Run(ctx, t, testInstallation)
5454
}

test/kubernetes/e2e/tests/validation_strict_tests.go

+14-1
Original file line numberDiff line numberDiff line change
@@ -7,12 +7,25 @@ import (
77
"github.com/solo-io/gloo/test/kubernetes/e2e/features/validation/validation_strict_warnings"
88
)
99

10+
// ValidationStrictSuiteRunnerAll is used to run all the validation tests, including ones that depend on the helm chart/values/helpers
11+
// This is the function that should be used to run the validation tests in this repo
12+
func ValidationStrictSuiteRunnerAll() e2e.SuiteRunner {
13+
validationSuiteRunner := ValidationStrictSuiteRunner()
14+
validationSuiteRunner.Register("ValidationSplitWebhook", split_webhook.NewTestingSuite)
15+
16+
return validationSuiteRunner
17+
}
18+
19+
// ValidationStrictSuiteRunner is used to export the validation tests that can be run when the project is imported as a helm dependency
20+
// The "ValidationSplitWebhook" test has logic that depends on the helm chart/values/helpers
21+
// that are not valid when the project is imported as a helm dependency
22+
// https://github.com/k8sgateway/k8sgateway/issues/10374 has been created to create a fix for this.
23+
// If more tests are added that depend on the helm chart/values/helpers, the above issue should be resolved instead of using this approach
1024
func ValidationStrictSuiteRunner() e2e.SuiteRunner {
1125
validationSuiteRunner := e2e.NewSuiteRunner(false)
1226

1327
validationSuiteRunner.Register("ValidationStrictWarnings", validation_strict_warnings.NewTestingSuite)
1428
validationSuiteRunner.Register("ValidationRejectInvalid", validation_reject_invalid.NewTestingSuite)
15-
validationSuiteRunner.Register("ValidationSplitWebhook", split_webhook.NewTestingSuite)
1629

1730
return validationSuiteRunner
1831
}

0 commit comments

Comments
 (0)