Skip to content

Commit

Permalink
lint: removed unnused func arg in the tests
Browse files Browse the repository at this point in the history
Signed-off-by: Guilherme Cassolato <[email protected]>
  • Loading branch information
guicassolato committed Oct 18, 2024
1 parent 043f265 commit 3f6871b
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions tests/istio/extension_reconciler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2457,7 +2457,7 @@ var _ = Describe("Rate Limiting WasmPlugin controller", func() {
Eventually(tests.GatewayIsReady(ctx, testClient(), gateway)).WithContext(ctx).Should(BeTrue())
}

expectedWasmPluginConfig := func(rlpKey client.ObjectKey, httpRoute *gatewayapiv1.HTTPRoute, key, hostname string) *wasm.Config {
expectedWasmPluginConfig := func(httpRoute *gatewayapiv1.HTTPRoute, key, hostname string) *wasm.Config {
mGateway := &machinery.Gateway{Gateway: gateway}
mHTTPRoute := &machinery.HTTPRoute{HTTPRoute: httpRoute}
pathID := kuadrantv1.PathID([]machinery.Targetable{
Expand Down Expand Up @@ -2566,7 +2566,7 @@ var _ = Describe("Rate Limiting WasmPlugin controller", func() {
Expect(testClient().Get(ctx, wasmPluginKey, existingWasmPlugin)).To(Succeed())
existingWASMConfig, err := wasm.ConfigFromStruct(existingWasmPlugin.Spec.PluginConfig)
Expect(err).ToNot(HaveOccurred())
Expect(existingWASMConfig).To(Equal(expectedWasmPluginConfig(gwRLPKey, httpRoute, controllers.LimitNameToLimitadorIdentifier(gwRLPKey, "gateway"), "*.example.com")))
Expect(existingWASMConfig).To(Equal(expectedWasmPluginConfig(httpRoute, controllers.LimitNameToLimitadorIdentifier(gwRLPKey, "gateway"), "*.example.com")))

// Create Route RLP
routeRLP := &kuadrantv1beta3.RateLimitPolicy{
Expand Down Expand Up @@ -2604,7 +2604,7 @@ var _ = Describe("Rate Limiting WasmPlugin controller", func() {
g.Expect(testClient().Get(ctx, wasmPluginKey, existingWasmPlugin)).To(Succeed())
existingWASMConfig, err = wasm.ConfigFromStruct(existingWasmPlugin.Spec.PluginConfig)
g.Expect(err).ToNot(HaveOccurred())
g.Expect(existingWASMConfig).To(Equal(expectedWasmPluginConfig(routeRLPKey, httpRoute, controllers.LimitNameToLimitadorIdentifier(routeRLPKey, "route"), "*.example.com")))
g.Expect(existingWASMConfig).To(Equal(expectedWasmPluginConfig(httpRoute, controllers.LimitNameToLimitadorIdentifier(routeRLPKey, "route"), "*.example.com")))
}).WithContext(ctx).Should(Succeed())

// Update GW RLP to overrides
Expand All @@ -2621,7 +2621,7 @@ var _ = Describe("Rate Limiting WasmPlugin controller", func() {
g.Expect(testClient().Get(ctx, wasmPluginKey, existingWasmPlugin)).To(Succeed())
existingWASMConfig, err = wasm.ConfigFromStruct(existingWasmPlugin.Spec.PluginConfig)
g.Expect(err).ToNot(HaveOccurred())
g.Expect(existingWASMConfig).To(Equal(expectedWasmPluginConfig(routeRLPKey, httpRoute, controllers.LimitNameToLimitadorIdentifier(routeRLPKey, "gateway"), "*.example.com")))
g.Expect(existingWASMConfig).To(Equal(expectedWasmPluginConfig(httpRoute, controllers.LimitNameToLimitadorIdentifier(routeRLPKey, "gateway"), "*.example.com")))
}).WithContext(ctx).Should(Succeed())

}, testTimeOut)
Expand Down

0 comments on commit 3f6871b

Please sign in to comment.