Skip to content

Commit

Permalink
skip setting http/2 of admin API if skipPatches disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
randmonkey committed Nov 23, 2023
1 parent f4065f1 commit 1622eda
Showing 1 changed file with 11 additions and 8 deletions.
19 changes: 11 additions & 8 deletions test/e2e/helpers_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -280,14 +280,17 @@ func (d ManifestDeploy) Run(ctx context.Context, t *testing.T, env environments.
t.Log("waiting for controller to be ready")
deployments := getManifestDeployments(d.Path)

adminAPINoHTTP2Range := kong.MustNewRange("<" + adminAPIHTTP2MinimalKongVersion.String())
kongVersion, err := getKongVersionFromOverrideImageTag()
if err == nil && adminAPINoHTTP2Range(kongVersion) {
t.Logf(
"Kong version %s is below %s, should disable HTTP/2 on admin API",
kongVersion.String(), adminAPIHTTP2MinimalKongVersion.String(),
)
removeAdminListenHTTP2(ctx, t, env, deployments.ProxyNN)
if !d.SkipTestPatches {
adminAPINoHTTP2Range := kong.MustNewRange("<" + adminAPIHTTP2MinimalKongVersion.String())
kongVersion, err := getKongVersionFromOverrideImageTag()
if err == nil && adminAPINoHTTP2Range(kongVersion) {
t.Logf(
"Kong version %s is below %s, should disable HTTP/2 on admin API",
kongVersion.String(), adminAPIHTTP2MinimalKongVersion.String(),
)
removeAdminListenHTTP2(ctx, t, env, deployments.ProxyNN)
}

}

waitForDeploymentRollout(ctx, t, env, deployments.ControllerNN.Namespace, deployments.ControllerNN.Name)
Expand Down

0 comments on commit 1622eda

Please sign in to comment.