Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
blame running out of coffee
  • Loading branch information
eguzki committed Nov 24, 2023
1 parent 541b35f commit 5fc58e4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions controllers/ratelimitpolicy_controller_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ var _ = Describe("RateLimitPolicy controller", func() {

// Check wasm plugin
wasmPluginKey := client.ObjectKey{Name: rlptools.WASMPluginName(gateway), Namespace: testNamespace}
Eventually(testWasmPluginIsAvailable(wasmPluginKey), time.Minute, 5*time.Second).To(BeTrue())
Eventually(testWasmPluginIsAvailable(wasmPluginKey), time.Minute, 5*time.Second).Should(BeTrue())
existingWasmPlugin := &istioclientgoextensionv1alpha1.WasmPlugin{}
err = k8sClient.Get(context.Background(), wasmPluginKey, existingWasmPlugin)
// must exist
Expand Down Expand Up @@ -312,7 +312,7 @@ var _ = Describe("RateLimitPolicy controller", func() {

// Check wasm plugin
wasmPluginKey := client.ObjectKey{Name: rlptools.WASMPluginName(gateway), Namespace: testNamespace}
Eventually(testWasmPluginIsAvailable(wasmPluginKey), time.Minute, 5*time.Second).To(BeTrue())
Eventually(testWasmPluginIsAvailable(wasmPluginKey), time.Minute, 5*time.Second).Should(BeTrue())
existingWasmPlugin := &istioclientgoextensionv1alpha1.WasmPlugin{}
err = k8sClient.Get(context.Background(), wasmPluginKey, existingWasmPlugin)
// must exist
Expand Down Expand Up @@ -482,7 +482,7 @@ var _ = Describe("RateLimitPolicy controller", func() {

// Check wasm plugin
wasmPluginKey := client.ObjectKey{Name: rlptools.WASMPluginName(gateway), Namespace: testNamespace}
Eventually(testWasmPluginIsAvailable(wasmPluginKey), time.Minute, 5*time.Second).To(BeTrue())
Eventually(testWasmPluginIsAvailable(wasmPluginKey), time.Minute, 5*time.Second).Should(BeTrue())
existingWasmPlugin := &istioclientgoextensionv1alpha1.WasmPlugin{}
err = k8sClient.Get(context.Background(), wasmPluginKey, existingWasmPlugin)
// must exist
Expand Down Expand Up @@ -601,7 +601,7 @@ var _ = Describe("RateLimitPolicy controller", func() {
// Check wasm plugin
wasmPluginKey := client.ObjectKey{Name: rlptools.WASMPluginName(gateway), Namespace: testNamespace}
// Wait a bit to catch cases where wasmplugin is created and takes a bit to be created
Eventually(testWasmPluginIsAvailable(wasmPluginKey), 20*time.Second, 5*time.Second).To(BeFalse())
Eventually(testWasmPluginIsAvailable(wasmPluginKey), 20*time.Second, 5*time.Second).Should(BeFalse())
existingWasmPlugin := &istioclientgoextensionv1alpha1.WasmPlugin{}
// must not exist
err = k8sClient.Get(context.Background(), wasmPluginKey, existingWasmPlugin)
Expand Down

0 comments on commit 5fc58e4

Please sign in to comment.