Skip to content

Commit f7f77a0

Browse files
committed
[RayService][e2e] fix flaky test in getting HTTPRoute
Signed-off-by: fscnick <fscnick.dev@gmail.com>
1 parent 86dbf04 commit f7f77a0

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

ray-operator/test/e2eincrementalupgrade/support.go

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -70,9 +70,10 @@ func bootstrapIncrementalRayService(
7070
g.Eventually(HTTPRoute(test, rayService.Namespace, httpRouteName), TestTimeoutMedium).
7171
Should(Not(BeNil()))
7272

73-
httpRoute, err = GetHTTPRoute(test, rayService.Namespace, httpRouteName)
74-
g.Expect(err).NotTo(HaveOccurred())
75-
g.Expect(utils.IsHTTPRouteReady(gateway, httpRoute)).To(BeTrue())
73+
g.Eventually(func() (bool, error) {
74+
httpRoute, err = GetHTTPRoute(test, rayService.Namespace, httpRouteName)
75+
return utils.IsHTTPRouteReady(gateway, httpRoute), err
76+
}, TestTimeoutMedium).Should(BeTrue())
7677

7778
gatewayIP = GetGatewayIP(gateway)
7879
g.Expect(gatewayIP).NotTo(BeEmpty())

0 commit comments

Comments
 (0)