Skip to content

Commit

Permalink
Add more cases in integ test
Browse files Browse the repository at this point in the history
Signed-off-by: Anshu Agarwal <anshukag@amazon.com>
  • Loading branch information
Anshu Agarwal committed Feb 7, 2023
1 parent 3e3053a commit 9dd3632
Showing 1 changed file with 15 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -662,5 +662,20 @@ public void testClusterHealthResponseWithEnsureNodeWeighedInParam() throws Excep
assertFalse(nodeLocalHealth.hasDiscoveredClusterManager());

networkDisruption.stopDisrupting();
Thread.sleep(1000);

// delete weights
ClusterDeleteWeightedRoutingResponse deleteResponse = client().admin().cluster().prepareDeleteWeightedRouting().setVersion(0).get();
assertTrue(deleteResponse.isAcknowledged());

// Check local cluster health
nodeLocalHealth = client(nodes_in_zone_c.get(0)).admin()
.cluster()
.prepareHealth()
.setLocal(true)
.setEnsureNodeWeighedIn(true)
.get();
assertFalse(nodeLocalHealth.isTimedOut());
assertTrue(nodeLocalHealth.hasDiscoveredClusterManager());
}
}

0 comments on commit 9dd3632

Please sign in to comment.