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

Only require a GatewayClass if the gateway suite is being run #2164

Merged
merged 2 commits into from
Jul 17, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions conformance/utils/suite/suite.go
Original file line number Diff line number Diff line change
Expand Up @@ -142,14 +142,15 @@ func New(s Options) *ConformanceTestSuite {
// Setup ensures the base resources required for conformance tests are installed
// in the cluster. It also ensures that all relevant resources are ready.
func (suite *ConformanceTestSuite) Setup(t *testing.T) {
t.Logf("Test Setup: Ensuring GatewayClass has been accepted")
suite.ControllerName = kubernetes.GWCMustHaveAcceptedConditionTrue(t, suite.Client, suite.TimeoutConfig, suite.GatewayClassName)

suite.Applier.GatewayClass = suite.GatewayClassName
suite.Applier.ControllerName = suite.ControllerName
suite.Applier.FS = suite.FS

if suite.SupportedFeatures.Has(SupportGateway) {
t.Logf("Test Setup: Ensuring GatewayClass has been accepted")
suite.ControllerName = kubernetes.GWCMustHaveAcceptedConditionTrue(t, suite.Client, suite.TimeoutConfig, suite.GatewayClassName)

suite.Applier.GatewayClass = suite.GatewayClassName
suite.Applier.ControllerName = suite.ControllerName

t.Logf("Test Setup: Applying base manifests")
suite.Applier.MustApplyWithCleanup(t, suite.Client, suite.TimeoutConfig, suite.BaseManifests, suite.Cleanup)

Expand Down