You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@shenyu.apache.org by GitBox <gi...@apache.org> on 2021/09/27 02:50:46 UTC

[GitHub] [incubator-shenyu] kevinBobo commented on a change in pull request #2146: [ISSUE #2128] Fix unit tests occasionally fail to execute.

kevinBobo commented on a change in pull request #2146:
URL: https://github.com/apache/incubator-shenyu/pull/2146#discussion_r716324885



##########
File path: shenyu-loadbalancer/src/test/java/org/apache/shenyu/loadbalancer/cache/UpstreamCheckTaskTest.java
##########
@@ -75,15 +75,15 @@ public void testRun() {
         healthCheckTask.schedule();
         // Wait for the upstream-health-check thread to start.
         Awaitility.await().pollDelay(3, TimeUnit.SECONDS).untilAsserted(() -> assertFalse(healthCheckTask.getCheckStarted().get()));
-        assertTrue(healthCheckTask.getHealthyUpstream().containsKey(selectorId1));
+        assertTrue(healthCheckTask.getUnhealthyUpstream().get(selectorId1).size() > 0);
         // Let it coverage line 151~163
         when(upstream.isHealthy()).thenReturn(false).thenReturn(true);

Review comment:
       I think the original author wants to change to return true when returning false。




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: notifications-unsubscribe@shenyu.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org